mirror of
https://git.code.sf.net/p/quake/newtree
synced 2025-06-02 10:01:54 +00:00
revert back to using f* for file io. I hope this fixes the catapult, but I wouldn't be suprised if it doesn't.
This commit is contained in:
parent
02eaf75b18
commit
e98edd5f5f
15 changed files with 113 additions and 115 deletions
|
@ -307,7 +307,7 @@ Cmd_Exec_File (char *path)
|
|||
char base[32];
|
||||
FILE *file;
|
||||
|
||||
if ((file = Qopen (path, "r")) != NULL) {
|
||||
if ((file = fopen (path, "r")) != NULL) {
|
||||
// extract the filename base name for hunk tag
|
||||
COM_FileBase (path, base);
|
||||
len = COM_filelength (file);
|
||||
|
@ -315,8 +315,8 @@ Cmd_Exec_File (char *path)
|
|||
f = (char *)Hunk_AllocName (len+1, base);
|
||||
if (f) {
|
||||
f[len] = 0;
|
||||
Qread (file, f, len);
|
||||
Qclose (file);
|
||||
fread (f, 1, len, file);
|
||||
fclose (file);
|
||||
Cbuf_InsertText (f);
|
||||
}
|
||||
Hunk_FreeToLowMark (mark);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue