/ Check-in [d3d491a5]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Merge several compiler compatibility fixes to trunk.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: d3d491a5461e21d84c6425977b80deedc7fa8a3a
User & Date: mistachkin 2012-06-21 14:05:15
Context
2012-06-21
14:25
Fix the SQLITE_ZERO_MALLOC compile-time option so that it works on windows. check-in: b80bc52f user: drh tags: trunk
14:05
Merge several compiler compatibility fixes to trunk. check-in: d3d491a5 user: mistachkin tags: trunk
13:00
Remove support for OS/2 from the source tree. check-in: ff828c67 user: drh tags: trunk
2012-06-18
17:15
Allow the SQLITE_API macro to apply to the sqlite3_win32_sleep function. Closed-Leaf check-in: 21266c68 user: mistachkin tags: compiler-compat
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to ext/fts3/fts3_unicode2.c.

   142    142           iLo = iTest+1;
   143    143         }else{
   144    144           iHi = iTest-1;
   145    145         }
   146    146       }
   147    147       assert( aEntry[0]<key );
   148    148       assert( key>=aEntry[iRes] );
   149         -    return (c >= ((aEntry[iRes]>>10) + (aEntry[iRes]&0x3FF)));
          149  +    return (((unsigned int)c) >= ((aEntry[iRes]>>10) + (aEntry[iRes]&0x3FF)));
   150    150     }
   151    151     return 1;
   152    152   }
   153    153   
   154    154   
   155    155   /*
   156    156   ** If the argument is a codepoint corresponding to a lowercase letter

Changes to src/mutex_w32.c.

   105    105   /* As winMutexInit() and winMutexEnd() are called as part
   106    106   ** of the sqlite3_initialize and sqlite3_shutdown()
   107    107   ** processing, the "interlocked" magic is probably not
   108    108   ** strictly necessary.
   109    109   */
   110    110   static long winMutex_lock = 0;
   111    111   
   112         -extern void sqlite3_win32_sleep(DWORD milliseconds); /* os_win.c */
          112  +void sqlite3_win32_sleep(DWORD milliseconds); /* os_win.c */
   113    113   
   114    114   static int winMutexInit(void){ 
   115    115     /* The first to increment to 1 does actual initialization */
   116    116     if( InterlockedCompareExchange(&winMutex_lock, 1, 0)==0 ){
   117    117       int i;
   118    118       for(i=0; i<ArraySize(winMutex_staticMutexes); i++){
   119    119   #if SQLITE_OS_WINRT

Changes to src/shell.c.

  2689   2689   ** 0 return indicates an error of some kind.
  2690   2690   */
  2691   2691   static char *find_home_dir(void){
  2692   2692     static char *home_dir = NULL;
  2693   2693     if( home_dir ) return home_dir;
  2694   2694   
  2695   2695   #if !defined(_WIN32) && !defined(WIN32) && !defined(_WIN32_WCE) && !defined(__RTP__) && !defined(_WRS_KERNEL)
  2696         -  struct passwd *pwent;
  2697         -  uid_t uid = getuid();
  2698         -  if( (pwent=getpwuid(uid)) != NULL) {
  2699         -    home_dir = pwent->pw_dir;
         2696  +  {
         2697  +    struct passwd *pwent;
         2698  +    uid_t uid = getuid();
         2699  +    if( (pwent=getpwuid(uid)) != NULL) {
         2700  +      home_dir = pwent->pw_dir;
         2701  +    }
  2700   2702     }
  2701   2703   #endif
  2702   2704   
  2703   2705   #if defined(_WIN32_WCE)
  2704   2706     /* Windows CE (arm-wince-mingw32ce-gcc) does not provide getenv()
  2705   2707      */
  2706   2708     home_dir = "/";