[SERVER-2651] update breaks with blank field name Created: 01/Mar/11  Updated: 12/Jul/16  Resolved: 03/Apr/12

Status: Closed
Project: Core Server
Component/s: Write Ops
Affects Version/s: None
Fix Version/s: 2.1.0

Type: Bug Priority: Major - P3
Reporter: Eliot Horowitz (Inactive) Assignee: Eric Milkie
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Operating System: ALL
Participants:

 Description   

See jstests/update_blank1.js



 Comments   
Comment by A. Jesse Jiryu Davis [ 03/Apr/12 ]

Resolved but not closed; I'm lobbying to have it backported to 2.0.x

Comment by auto [ 02/Dec/11 ]

Author:

{u'login': u'milkie', u'name': u'Eric Milkie', u'email': u'milkie@10gen.com'}

Message: better support for blank field names when comparing them: SERVER-2651

When passing a blank field name as the second parameter to compareDottedFieldNames, the function
was returning LEFT_SUBFIELD. By reordering the logic so that we only check for subfields after
the first lexicographic compare, we now return the correct answer.
The code change will not affect other cases because the subfield tests test to see if we've reached
the end of the strings with our parsing. Before the first iteration of the loop, this situation will
never be true unless one of the field names is blank.
Branch: master
https://github.com/mongodb/mongo/commit/3588c09d3572ca1aedfda6e79dc5bf0883eac686

Comment by auto [ 01/Mar/11 ]

Author:

{u'login': u'erh', u'name': u'Eliot Horowitz', u'email': u'eliot@10gen.com'}

Message: test for SERVER-2651
https://github.com/mongodb/mongo/commit/ea825cd6c763f80d96a2199d196416dd9c6fafd8

Generated at Thu Feb 08 03:00:47 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.