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_import.c | |
parent | 10cb49f302ab1084c5b86d4c47da17d8abf09159 (diff) | |
download | execline-54979a7b81a397eca8438d3def2a0fe5b19825e0.tar.xz |
Fix a few omissions
Diffstat (limited to 'src/libexecline/exlsn_import.c')
-rw-r--r-- | src/libexecline/exlsn_import.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libexecline/exlsn_import.c b/src/libexecline/exlsn_import.c index ff05113..254ab78 100644 --- a/src/libexecline/exlsn_import.c +++ b/src/libexecline/exlsn_import.c @@ -1,6 +1,6 @@ /* ISC license. */ -#include <skalibs/bytestr.h> +#include <string.h> #include <skalibs/sgetopt.h> #include <skalibs/strerr2.h> #include <skalibs/stralloc.h> @@ -42,7 +42,7 @@ static int exlsn_import_as (int argc, char const **argv, char const *const *envp if ((unsigned int)argc < 1+as) 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 ; x = env_get2(envp, argv[as]) ; if (!x) { @@ -51,7 +51,7 @@ static int exlsn_import_as (int argc, char const **argv, char const *const *envp } else if (unexport) { - if (!stralloc_catb(&info->modifs, argv[as], str_len(argv[as]) + 1)) goto err ; + if (!stralloc_catb(&info->modifs, argv[as], strlen(argv[as]) + 1)) goto err ; } if (!x) blah.n = 0 ; else |