stijnsanders / TMongoWire

Delphi MongoDB driver
MIT License
102 stars 37 forks source link

toughen IBSONDocumentEnumerator against null elements #25

Open stijnsanders opened 9 years ago

scaleman114 commented 7 years ago

Hi, Just trying out example1 and getting an 'invalid pointer error' when trying to refresh or load documents with a null field. Will you be looking at this anytime soon? Thanks

stijnsanders commented 7 years ago

It's not strictly related to this issue, but there was indeed a bug. Please update to the recent commit.

stijnsanders commented 7 years ago

Then again. Having a second look, this bug may have caused me to post this issue way back then. If I try IBSONEnumerator over {{x:1},null,{x:2}} now it now fails because Can't mix documents and non-documents with IBSONDocumentEnumerator. If I were ever to make IBSONDocumentEnumerator support null elements in the array, I'd have to change: