diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2017-03-12 13:24:30 +0000 |
---|---|---|
committer | Laurent Bercot <ska-skaware@skarnet.org> | 2017-03-12 13:24:30 +0000 |
commit | 54979a7b81a397eca8438d3def2a0fe5b19825e0 (patch) | |
tree | 4dac9941e6bca1d693cfb9c0388abdb96e202fcb /src/libexecline/exlsn_elglob.c | |
parent | 10cb49f302ab1084c5b86d4c47da17d8abf09159 (diff) | |
download | execline-54979a7b81a397eca8438d3def2a0fe5b19825e0.tar.xz |
Fix a few omissions
Diffstat (limited to 'src/libexecline/exlsn_elglob.c')
-rw-r--r-- | src/libexecline/exlsn_elglob.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libexecline/exlsn_elglob.c b/src/libexecline/exlsn_elglob.c index e64c598..62734e6 100644 --- a/src/libexecline/exlsn_elglob.c +++ b/src/libexecline/exlsn_elglob.c @@ -2,7 +2,7 @@ #include <errno.h> #include <glob.h> -#include <skalibs/bytestr.h> +#include <string.h> #include <skalibs/sgetopt.h> #include <skalibs/strerr2.h> #include <skalibs/stralloc.h> @@ -46,7 +46,7 @@ int exlsn_elglob (int argc, char const **argv, char const *const *envp, exlsn_t if (argc < 2) return -3 ; if (!*argv[0] || el_vardupl(argv[0], info->vars.s, info->vars.len)) return -2 ; - if (!stralloc_catb(&info->vars, argv[0], str_len(argv[0]) + 1)) return -1 ; + if (!stralloc_catb(&info->vars, argv[0], strlen(argv[0]) + 1)) return -1 ; pglob.gl_offs = 0 ; switch (glob(argv[1], flags, verbose ? &elgloberrfunc : 0, &pglob)) @@ -61,7 +61,7 @@ int exlsn_elglob (int argc, char const **argv, char const *const *envp, exlsn_t default: goto err ; } for ( ; i < (unsigned int)pglob.gl_pathc ; i++) - if (!stralloc_catb(&info->values, pglob.gl_pathv[i], str_len(pglob.gl_pathv[i]) + 1)) + if (!stralloc_catb(&info->values, pglob.gl_pathv[i], strlen(pglob.gl_pathv[i]) + 1)) goto globerr ; blah.n = pglob.gl_pathc ; globfree(&pglob) ; |