Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F136747600
D3204.id7334.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
658 B
Referenced Files
None
Subscribers
None
D3204.id7334.diff
View Options
Index: sys/boot/common/module.c
===================================================================
--- sys/boot/common/module.c
+++ sys/boot/common/module.c
@@ -102,6 +102,7 @@
static int
command_load(int argc, char *argv[])
{
+ struct preloaded_file *fp;
char *typestr;
int dofile, dokld, ch, error;
@@ -139,6 +140,13 @@
command_errmsg = "invalid load type";
return(CMD_ERROR);
}
+
+ fp = file_findfile(argv[1], typestr);
+ if (fp) {
+ sprintf(command_errbuf, "warning: file '%s' already loaded", argv[1]);
+ return (CMD_ERROR);
+ }
+
return (file_loadraw(argv[1], typestr, 1) ? CMD_OK : CMD_ERROR);
}
/*
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 20, 6:00 AM (5 h, 36 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
25710932
Default Alt Text
D3204.id7334.diff (658 B)
Attached To
Mode
D3204: Fix loading files twice.
Attached
Detach File
Event Timeline
Log In to Comment