Changeset 15932 in project for chicken


Ignore:
Timestamp:
09/17/09 01:51:44 (10 years ago)
Author:
kon
Message:

Fix for binary image pathname extension check on Windows. Was comparing too many chars. Added errmsg for wrong extn.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/runtime.c

    r15918 r15932  
    87448744  /* cannot use LoadLibrary on non-DLLs, so we use extension checking */
    87458745  int len = strlen(name);
    8746   if(   (len >= 5 && C_strncasecmp(".dll", name+len-5, 4))
    8747      && (len >= 4 && C_strncasecmp(".so", name+len-4, 3))) {
    8748     /* FIXME - really should have an error for this */
    8749     C_dlerror = NULL;
     8746  /* FIXME - probably should use _stricmp since Windows native */
     8747  if(   (len >= 5 && C_strncasecmp(".dll", name+len-4, 4))
     8748     && (len >= 4 && C_strncasecmp(".so", name+len-3, 3))) {
     8749    static char not_dll_msg[] = "unsuitable pathname extension - not a .DLL or .SO";
     8750    C_dlerror = not_dll_msg;
    87508751    return NULL;
    87518752  }
Note: See TracChangeset for help on using the changeset viewer.