/[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 967 by johnpye, Thu Nov 23 04:31:19 2006 UTC revision 968 by johnpye, Mon Dec 18 05:49:00 2006 UTC
# Line 283  int importhandler_search_test(struct Fil Line 283  int importhandler_search_test(struct Fil
283    
284      searchdata = (struct ImportHandlerSearch *)userdata;      searchdata = (struct ImportHandlerSearch *)userdata;
285    
286      char *pathcomponent;      /* char *pathcomponent;
287      pathcomponent = ospath_str(path); /* eg '/home/john' */      pathcomponent = ospath_str(path); //eg '/home/john'
288      /* CONSOLE_DEBUG("In directory '%s'...",pathcomponent); */      CONSOLE_DEBUG("In directory '%s'...",pathcomponent);
289      ASC_FREE(pathcomponent);      ASC_FREE(pathcomponent); */
290    
291      asc_assert(importhandler_library!=NULL);      asc_assert(importhandler_library!=NULL);
292    
# Line 302  int importhandler_search_test(struct Fil Line 302  int importhandler_search_test(struct Fil
302          ASC_FREE(filename);          ASC_FREE(filename);
303          asc_assert(fp!=NULL);          asc_assert(fp!=NULL);
304    
305          fullpath = ospath_str(searchdata->relativedir);          /* fullpath = ospath_str(searchdata->relativedir);
306          /* CONSOLE_DEBUG("Relative dir is '%s'",fullpath); */          CONSOLE_DEBUG("Relative dir is '%s'",fullpath);
307          ASC_FREE(fullpath);          ASC_FREE(fullpath); */
308    
309          fp1 = ospath_concat(path,searchdata->relativedir); /* eg '/home/john/path/to' */          fp1 = ospath_concat(path,searchdata->relativedir); /* eg '/home/john/path/to' */
310          asc_assert(fp1!=NULL);          asc_assert(fp1!=NULL);
311    
312          fullpath = ospath_str(fp1);          /*fullpath = ospath_str(fp1);
313          /* CONSOLE_DEBUG("Path is '%s'",fullpath); */          CONSOLE_DEBUG("Path is '%s'",fullpath);
314          ASC_FREE(fullpath);          ASC_FREE(fullpath);*/
315    
316          fullpath = ospath_str(fp);          /*fullpath = ospath_str(fp);
317          /* CONSOLE_DEBUG("Filename is '%s'",fullpath); */          CONSOLE_DEBUG("Filename is '%s'",fullpath);
318          ASC_FREE(fullpath);          ASC_FREE(fullpath);*/
319    
320          fp2 = ospath_concat(fp1,fp); /* eg '/home/john/path/to/libmyext.so' */          fp2 = ospath_concat(fp1,fp); /* eg '/home/john/path/to/libmyext.so' */
321          asc_assert(fp2!=NULL);          asc_assert(fp2!=NULL);
322          ospath_free(fp1);          ospath_free(fp1);
323          ospath_free(fp);          ospath_free(fp);
324    
325          fullpath = ospath_str(fp2);          /* fullpath = ospath_str(fp2);
326          /* CONSOLE_DEBUG("Checking for readable '%s'",fullpath); */          CONSOLE_DEBUG("Checking for readable '%s'",fullpath);
327          ASC_FREE(fullpath);          ASC_FREE(fullpath); */
328    
329          if(0==ospath_stat(fp2,&buf) && NULL!=(f = ospath_fopen(fp2,"r"))){          if(0==ospath_stat(fp2,&buf) && NULL!=(f = ospath_fopen(fp2,"r"))){
330              fclose(f);              fclose(f);

Legend:
Removed from v.967  
changed lines
  Added in v.968

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