diff options
| author | Wayne Davison <wayned@samba.org> | 2006-10-13 23:17:33 +0000 |
|---|---|---|
| committer | Wayne Davison <wayned@samba.org> | 2006-10-13 23:17:33 +0000 |
| commit | c9bce0b8f8a485f11ce4f90356e9346036f14daf (patch) | |
| tree | f7583d1eefa8781e7122e0b84d2b83e32a022c36 /tls.c | |
| parent | deee574b1198a2886369f4ecbfbeaa6f851bb41d (diff) | |
| download | android_external_rsync-c9bce0b8f8a485f11ce4f90356e9346036f14daf.tar.gz android_external_rsync-c9bce0b8f8a485f11ce4f90356e9346036f14daf.tar.bz2 android_external_rsync-c9bce0b8f8a485f11ce4f90356e9346036f14daf.zip | |
Changed strcpy() calls into strlcpy() calls, just to be extra safe.
Diffstat (limited to 'tls.c')
| -rw-r--r-- | tls.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -74,7 +74,7 @@ static void list_file(const char *fname) buf.st_mode &= ~0777; buf.st_mtime = (time_t)0; buf.st_uid = buf.st_gid = 0; - strcpy(linkbuf, " -> "); + strlcpy(linkbuf, " -> ", sizeof linkbuf); /* const-cast required for silly UNICOS headers */ len = readlink((char *) fname, linkbuf+4, sizeof(linkbuf) - 4); if (len == -1) @@ -99,7 +99,7 @@ static void list_file(const char *fname) (int)mt->tm_min, (int)mt->tm_sec); } else { - strcpy(datebuf, " "); + strlcpy(datebuf, " ", sizeof datebuf); } /* TODO: Perhaps escape special characters in fname? */ |
