diff options
author | miod <> | 2007-10-20 12:35:54 +0000 |
---|---|---|
committer | miod <> | 2007-10-20 12:35:54 +0000 |
commit | 1af04725f287a6fe50818cb67f9b2b7b6e664249 (patch) | |
tree | e06b9ef4225678354eefbf1b882f2868be42e458 /src | |
parent | 115b8b7d4830ff4c5f4180f7d64cd57307f5f909 (diff) | |
download | openbsd-1af04725f287a6fe50818cb67f9b2b7b6e664249.tar.gz openbsd-1af04725f287a6fe50818cb67f9b2b7b6e664249.tar.bz2 openbsd-1af04725f287a6fe50818cb67f9b2b7b6e664249.zip |
Make this work on 64 bit platforms by using strlen() instead of sizeof()...
worked by accident.
Diffstat (limited to 'src')
-rw-r--r-- | src/regress/lib/libc/dirname/dirname_test.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/regress/lib/libc/dirname/dirname_test.c b/src/regress/lib/libc/dirname/dirname_test.c index 7d0b0e221f..0dd95d6c30 100644 --- a/src/regress/lib/libc/dirname/dirname_test.c +++ b/src/regress/lib/libc/dirname/dirname_test.c | |||
@@ -69,7 +69,7 @@ main(void) | |||
69 | 69 | ||
70 | /* Case 4 */ | 70 | /* Case 4 */ |
71 | strlcpy(path, "/", sizeof(path)); /* reset path */ | 71 | strlcpy(path, "/", sizeof(path)); /* reset path */ |
72 | for (i = 0; i <= MAXPATHLEN; i += sizeof(dir)) | 72 | for (i = 0; i <= MAXPATHLEN; i += strlen(dir)) |
73 | strlcat(path, dir, sizeof(path)); | 73 | strlcat(path, dir, sizeof(path)); |
74 | strlcat(path, fname, sizeof(path)); | 74 | strlcat(path, fname, sizeof(path)); |
75 | str = dirname(path); | 75 | str = dirname(path); |