/[ascend]/trunk/base/generic/compiler/importhandler.c
ViewVC logotype

Diff of /trunk/base/generic/compiler/importhandler.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 864 by johnpye, Thu Sep 28 13:39:16 2006 UTC revision 865 by johnpye, Thu Sep 28 14:19:17 2006 UTC
# Line 65  ASC_DLLSPEC(int) importhandler_add(struc Line 65  ASC_DLLSPEC(int) importhandler_add(struc
65          return 1;          return 1;
66      }      }
67      importhandler_library[i] = handler;      importhandler_library[i] = handler;
68        ERROR_REPORTER_HERE(ASC_PROG_NOTE,"New import hander '%s' added",handler->name);
69      return 0;      return 0;
70  }  }
71    
# Line 185  int importhandler_createlibrary(){ Line 186  int importhandler_createlibrary(){
186      struct ImportHandler *extlib_handler;      struct ImportHandler *extlib_handler;
187    
188      if(importhandler_library!=NULL){      if(importhandler_library!=NULL){
189          ERROR_REPORTER_HERE(ASC_PROG_ERR,"Already created");          /* ERROR_REPORTER_HERE(ASC_PROG_ERR,"Already created"); */
190          return 1;          return 0;
191      };      };
192      importhandler_library=ASC_NEW_ARRAY(struct ImportHandler *,IMPORTHANDLER_MAX);      importhandler_library=ASC_NEW_ARRAY(struct ImportHandler *,IMPORTHANDLER_MAX);
193      for(i=0; i < IMPORTHANDLER_MAX; ++i){      for(i=0; i < IMPORTHANDLER_MAX; ++i){
# Line 299  int importhandler_search_test(struct Fil Line 300  int importhandler_search_test(struct Fil
300    
301          fp1 = ospath_concat(path,searchdata->relativedir); /* eg '/home/john/path/to' */          fp1 = ospath_concat(path,searchdata->relativedir); /* eg '/home/john/path/to' */
302          asc_assert(fp1!=NULL);          asc_assert(fp1!=NULL);
         ospath_free(fp);  
303    
304          fullpath = ospath_str(fp1);          fullpath = ospath_str(fp1);
305          CONSOLE_DEBUG("Path is '%s'",fullpath);          CONSOLE_DEBUG("Path is '%s'",fullpath);
306          ASC_FREE(fullpath);          ASC_FREE(fullpath);
307    
308            fullpath = ospath_str(fp);
309            CONSOLE_DEBUG("Filename is '%s'",fullpath);
310            ASC_FREE(fullpath);
311    
312          fp2 = ospath_concat(fp1,fp); /* eg '/home/john/path/to/libmyext.so' */          fp2 = ospath_concat(fp1,fp); /* eg '/home/john/path/to/libmyext.so' */
313          asc_assert(fp2!=NULL);          asc_assert(fp2!=NULL);
314          ospath_free(fp1);          ospath_free(fp1);
315            ospath_free(fp);
316    
317          fullpath = ospath_str(fp2);          fullpath = ospath_str(fp2);
318          CONSOLE_DEBUG("Checking for readable '%s'",fullpath);          CONSOLE_DEBUG("Checking for readable '%s'",fullpath);

Legend:
Removed from v.864  
changed lines
  Added in v.865

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22