Mercurial > octave
comparison kpathsea/pathsearch.c @ 1272:7949d2e66339
[project @ 1995-04-21 00:19:28 by jwe]
author | jwe |
---|---|
date | Fri, 21 Apr 1995 00:19:28 +0000 |
parents | abaf21f34109 |
children | ae70cd47bb1c |
comparison
equal
deleted
inserted
replaced
1271:ffecaa9b9892 | 1272:7949d2e66339 |
---|---|
328 | 328 |
329 string | 329 string |
330 kpse_path_search P3C(const_string, path, const_string, name, | 330 kpse_path_search P3C(const_string, path, const_string, name, |
331 boolean, must_exist) | 331 boolean, must_exist) |
332 { | 332 { |
333 static string *ret_list; | 333 static string *ret_list = 0 |
334 | 334 |
335 if (ret_list) | 335 if (ret_list) |
336 free (ret_list); | 336 { |
337 free (ret_list); | |
338 ret_list = 0; /* Don't let an interrupt in search() cause trouble */ | |
339 } | |
337 | 340 |
338 ret_list = search (path, name, must_exist, false); | 341 ret_list = search (path, name, must_exist, false); |
339 | 342 |
340 return *ret_list; /* Freeing this is caller's responsibility */ | 343 return *ret_list; /* Freeing this is caller's responsibility */ |
341 } | 344 } |