Branch: Tag:

2015-04-02

2015-04-02 14:46:02 by Bill Welliver <bill@welliver.org>

windows: strdup is deprecated.

96:   {    if( master_file_location != _master_location+CONSTANT_STRLEN(MASTER_COOKIE))    free((void*)master_file_location); + #if DEBUG_MALLOC + #ifndef __NT__   #undef strdup /* We can't use dmalloc strdup before pike_memory is initialized. */ -  + #else + #define strdup _strdup + #endif /* __NT__ */ + #endif /* DEBUG_MALLOC */    master_file_location = strdup( file );   }   
104: Inside #if defined(__NT__)
  static void get_master_key(HKEY cat)   {    HKEY k; -  char buffer[4096]; +  char * buffer = malloc(4096);    DWORD len=sizeof(buffer)-1,type=REG_SZ;       if(RegOpenKeyEx(cat,
161: Inside #if defined(__NT__)
   fprintf (stderr, "Failed to get path to exe file: %d\n",    GetLastError());    else { -  char tmp[MAXPATHLEN * 2]; +  char * tmp = malloc(MAXPATHLEN * 2);    char *p = strrchr (exepath, '\\');    if (p) *p = 0;    snprintf (tmp, sizeof (tmp), "%s/%s", exepath, mp);
293:    JMP_BUF back;    int e, num;    char *p; -  +    #ifdef PIKE_EXTRA_DEBUG    if (sizeof(void *) == 8) {    /* 64-bit Solaris 10 in Xenofarm fails with SIGPIPE.