summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKarl Heuer <kwzh@gnu.org>1994-03-18 00:13:40 +0000
committerKarl Heuer <kwzh@gnu.org>1994-03-18 00:13:40 +0000
commit5a6e5452167f81878a8af4a31e884822a95a6a59 (patch)
tree8573e313511daf4b3c46f42c28c1b4b613113a05 /src
parentc52b0b3467ce9a1c4dc02ce133a09d536d23524f (diff)
downloademacs-5a6e5452167f81878a8af4a31e884822a95a6a59.tar.gz
(openp, Fload): GCPRO some things.
Diffstat (limited to 'src')
-rw-r--r--src/lread.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/lread.c b/src/lread.c
index 8649d8a6694..ccb2f52d238 100644
--- a/src/lread.c
+++ b/src/lread.c
@@ -353,8 +353,10 @@ Return t if file exists.")
since it would try to load a directory as a Lisp file */
if (XSTRING (str)->size > 0)
{
+ GCPRO1 (str);
fd = openp (Vload_path, str, !NILP (nosuffix) ? "" : ".elc:.el:",
&found, 0);
+ UNGCPRO;
}
if (fd < 0)
@@ -505,7 +507,9 @@ openp (path, str, suffix, storeptr, exec_only)
int want_size;
register Lisp_Object filename;
struct stat st;
+ struct gcpro gcpro1;
+ GCPRO1 (str);
if (storeptr)
*storeptr = Qnil;
@@ -563,7 +567,7 @@ openp (path, str, suffix, storeptr, exec_only)
/* We succeeded; return this descriptor and filename. */
if (storeptr)
*storeptr = build_string (fn);
- return fd;
+ RETURN_UNGCPRO (fd);
}
}
@@ -572,10 +576,11 @@ openp (path, str, suffix, storeptr, exec_only)
break;
nsuffix += lsuffix + 1;
}
- if (absolute) return -1;
+ if (absolute)
+ RETURN_UNGCPRO (-1);
}
- return -1;
+ RETURN_UNGCPRO (-1);
}