Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-4221

Compile warning under mingw-w64

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 1.20.0
    • Affects Version/s: None
    • Component/s: None
    • None

      Hello, I am the maintainer of the mongolite R package.

      I am trying to upgrade the vendored mongo-c-driver to the latest 1.19.2 but I am blocked by a compiler warning that we see on Windows:

       

      bson/bson-atomic.c:86:35: warning: passing argument 1 of 'InterlockedExchangeAdd' from incompatible pointer type [-Wincompatible-pointer-types] 
      bson/bson-atomic.c:93:35: warning: passing argument 1 of 'InterlockedExchangeAdd' from incompatible pointer type [-Wincompatible-pointer-types]
      

       

      The exact warning is:

       

      C:/rtools40/mingw64/x86_64-w64-mingw32/include/psdk_inc/intrin-impl.h:1026:53: note: expected 'volatile long int *' but argument is of type 'volatile int32_t *' {aka 'volatile int *'} 

       

      We use gcc-8.3.0 with mingw-w64 5.x though I don't think that matters.

            Assignee:
            colby.pike@mongodb.com Colby Pike
            Reporter:
            jeroenooms@gmail.com Jeroen Ooms
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: