<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:36:30 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[GODRIVER-1488] Decode struct infinite recursion with mgocompat Registry </title>
                <link>https://jira.mongodb.org/browse/GODRIVER-1488</link>
                <project id="14289" key="GODRIVER">Go Driver</project>
                    <description>&lt;p&gt;&lt;span class=&quot;nobr&quot;&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/attachment/247206/247206_main.go&quot; title=&quot;main.go attached to GODRIVER-1488&quot;&gt;main.go&lt;sup&gt;&lt;img class=&quot;rendericon&quot; src=&quot;https://jira.mongodb.org/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/sup&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&lt;sup&gt;The attached program triggers the issue.&#160; It would seem to be a missing nil check somewhere in this call:&lt;/sup&gt;&lt;/p&gt;



&lt;p&gt;if sc.DecodeDeepZeroInline &amp;amp;&amp;amp; sd.inline &lt;/p&gt;
{
 val.Set(deepZero(val.Type()))
}

&lt;p&gt;at&#160;go.mongodb.org/mongo-driver@v1.3.0/bson/bsoncodec/struct_codec.go:198&lt;/p&gt;


&lt;p&gt;Removing the draft field bypasses the issue.&#160; Replacing the embedded Common struct with the ID field also bypasses the issue, so there is something in the intersection of those two fields.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1144049">GODRIVER-1488</key>
            <summary>Decode struct infinite recursion with mgocompat Registry </summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="13201">Fixed</resolution>
                                        <assignee username="isabella.siu@mongodb.com">Isabella Siu</assignee>
                                    <reporter username="jkingston@istreamplanet.com">James Kingston</reporter>
                        <labels>
                    </labels>
                <created>Wed, 12 Feb 2020 03:35:40 +0000</created>
                <updated>Sat, 28 Oct 2023 11:38:20 +0000</updated>
                            <resolved>Thu, 27 Feb 2020 16:31:46 +0000</resolved>
                                    <version>1.3.0</version>
                                    <fixVersion>1.3.1</fixVersion>
                                    <component>BSON</component>
                    <component>mgobson</component>
                                        <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="2914485" author="xgen-internal-githook" created="Thu, 27 Feb 2020 16:23:44 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;username&apos;: &apos;iwysiu&apos;, &apos;name&apos;: &apos;iwysiu&apos;, &apos;email&apos;: &apos;isabella.siu@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/GODRIVER-1488&quot; title=&quot;Decode struct infinite recursion with mgocompat Registry &quot; class=&quot;issue-link&quot; data-issue-key=&quot;GODRIVER-1488&quot;&gt;&lt;del&gt;GODRIVER-1488&lt;/del&gt;&lt;/a&gt; turn off DecodeDeepZeroInline for mgocompat.Registry (#312)&lt;br/&gt;
Branch: release/1.3&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/commit/4daf0f2ebe5787b97d73ae49d42d723605b53969&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-go-driver/commit/4daf0f2ebe5787b97d73ae49d42d723605b53969&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2914387" author="xgen-internal-githook" created="Thu, 27 Feb 2020 15:54:37 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;username&apos;: &apos;iwysiu&apos;, &apos;name&apos;: &apos;iwysiu&apos;, &apos;email&apos;: &apos;isabella.siu@10gen.com&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/GODRIVER-1488&quot; title=&quot;Decode struct infinite recursion with mgocompat Registry &quot; class=&quot;issue-link&quot; data-issue-key=&quot;GODRIVER-1488&quot;&gt;&lt;del&gt;GODRIVER-1488&lt;/del&gt;&lt;/a&gt; turn off DecodeDeepZeroInline for mgocompat.Registry (#312)&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-go-driver/commit/026d01fa5aaf56799a8ae2c6ec2da402292e0996&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-go-driver/commit/026d01fa5aaf56799a8ae2c6ec2da402292e0996&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="2889293" author="isabella.siu" created="Fri, 21 Feb 2020 19:41:26 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=jkingston%40istreamplanet.com&quot; class=&quot;user-hover&quot; rel=&quot;jkingston@istreamplanet.com&quot;&gt;jkingston@istreamplanet.com&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;We investigated this, and found that it was introduced by a change on globalsign/mgo&apos;s dev branch that was meant to support inline struct pointers. That change made it so that if a struct contained an inline field, it would zero initialize structs for all of its struct pointers, which introduces this bug.&lt;/p&gt;

&lt;p&gt;We are going to change mgoRegistry to use our BSON library&apos;s inline struct pointer logic, which only zero initializes structs for inline struct pointers when the struct is used. While this is a behavior change, we feel that it is more intuitive for users.&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="247206" name="main.go" size="922" author="jkingston@istreamplanet.com" created="Wed, 12 Feb 2020 03:29:51 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr8ban:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>