Skip to content

Commit acf41ce

Browse files
committed
Clean up quote_fname, quote_fname_ufs, and quote_dname
Moves definitions of the quote_xxx functions from ufs.c where they are not used to dir.c where they are used. Adds a parameter to each of the quote_xxx functions to supply the length of the storage allocated for the result string, and change strcpy() to strlcpy() to avoid potential memory smash if used carelessly.
1 parent c86190b commit acf41ce

File tree

3 files changed

+245
-244
lines changed

3 files changed

+245
-244
lines changed

inc/ufsdefs.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@ int unixpathname(char *src, char *dst, int dstlen, int versionp, int genp, char
1111
int unixpathname(char *src, char *dst, size_t dstlen, int versionp, int genp);
1212
#endif
1313
int lisppathname(char *fullname, char *lispname, size_t lispnamesize, int dirp, int versionp);
14-
int quote_fname(char *file);
15-
int quote_fname_ufs(char *file);
16-
int quote_dname(char *dir);
1714
#ifdef DOS
1815
init_host_filesystem(void);
1916
exit_host_filesystem(void);

0 commit comments

Comments
 (0)