summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2015-07-13 11:12:02 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2015-07-13 11:12:02 +0000
commitadfb443fe0cee7961d0c601f98215981e55b9942 (patch)
tree8619169a148fa72bc5463cc15435da7071c0bc41
parente37572acace0cb66d741c378ead5d01684e53521 (diff)
downloads6-rc-adfb443fe0cee7961d0c601f98215981e55b9942.tar.xz
Without typos, if possible
-rw-r--r--src/s6-rc/s6-rc-compile.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/s6-rc/s6-rc-compile.c b/src/s6-rc/s6-rc-compile.c
index dfee167..97990a1 100644
--- a/src/s6-rc/s6-rc-compile.c
+++ b/src/s6-rc/s6-rc-compile.c
@@ -486,14 +486,14 @@ static inline void add_sources (before_t *be, char const *srcdir)
struct stat st ;
int fd ;
direntry *d ;
- satmp.len = cur ;
errno = 0 ;
d = readdir(dir) ;
if (!d) break ;
if (d->d_name[0] == '.') continue ;
if (d->d_name[str_chr(d->d_name, '\n')])
strerr_dief3x(2, "subdirectory of ", srcdir, " contains a newline character") ;
- if (!stralloc_catb(&satmp, d->d_name, str_len(d->d_name + 1)) dienomem() ;
+ satmp.len = cur ;
+ if (!stralloc_catb(&satmp, d->d_name, str_len(d->d_name) + 1)) dienomem() ;
if (lstat(satmp.s + start, &st) < 0)
strerr_diefu2sys(111, "lstat ", satmp.s + start) ;
if (!S_ISDIR(st.st_mode)) continue ;