Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-188

Found a severe problem with the C extension running with MRI 1.9.2p0 on Windows *only*

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Blocker - P1 Blocker - P1
    • 1.2-rc0
    • Affects Version/s: 1.1.0
    • Component/s: None
    • Labels:
      None
    • Environment:
      Win7 x64, Ruby 1.9.1p430, Ruby 1.9.2p0, DevKit 4.5 (all from Rubyinstaller.org)

      Inserting data using MRI 1.9.2p0 is incorrect. It doesn't fail, but viewing the data with the mongo console shows that all values are "null". Even weirder, I can mongodump the collection and bsondump to json format and the data is CORRECT even though the mongo console told me it was all null!

      Comparing the output of bsondump in debug mode shows that something is very wrong.

      The following gist shows that this works okay with MRI 1.9.1p430 and fails with 1.9.2p0.

      http://gist.github.com/618491

      I confirmed this is related to the C extension. Removing the C extension and doing a pure ruby insert from 1.9.2p0 works as expected.

      (When viewing through mongo console, the pure ruby insert shows the number directly. Using MRI 1.9.1p430 and the C extension lists all integers as NumberLong( x ), so the C extension that does work has slightly different behavior than the C extension on linux/osx.)

      I was only able to reproduce this on Windows; I could not reproduce on UNIX.

            Assignee:
            kbanker Kyle Banker
            Reporter:
            cremes Chuck Remes
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: