From 33263c74c5cee593baaab14310345da023e626ab Mon Sep 17 00:00:00 2001 From: jjgarcia Date: Tue, 12 Feb 2002 15:59:15 +0000 Subject: [PATCH] Hannu Koivisto: Now respects if-does-not-exist argument in all case --- src/c/load.d | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/c/load.d b/src/c/load.d index 51c2ce962..e94108f67 100644 --- a/src/c/load.d +++ b/src/c/load.d @@ -146,9 +146,11 @@ GO_ON: /* If filename already has an extension, make sure that the file exists */ filename = coerce_to_filename(pathname); - if (!file_exists(filename)) - FEcannot_open(filename); - function = cdr(assoc(pathname->pathname.type, hooks)); + if (!file_exists(filename)) { + filename = Cnil; + } else { + function = cdr(assoc(pathname->pathname.type, hooks)); + } } else loop_for_in(hooks) { /* Otherwise try with known extensions until a matching file is found */