From: Michihiro NAKAJIMA Date: Mon, 25 Apr 2011 10:44:29 +0000 (-0400) Subject: Correct a length argument to invalid_mbs(). X-Git-Tag: v3.0.0a~415 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a5c9840339a135e159bbcc8d54d5220771a0d986;p=thirdparty%2Flibarchive.git Correct a length argument to invalid_mbs(). SVN-Revision: 3271 --- diff --git a/libarchive/archive_string.c b/libarchive/archive_string.c index da767808d..fb2118dd0 100644 --- a/libarchive/archive_string.c +++ b/libarchive/archive_string.c @@ -1646,7 +1646,7 @@ best_effort_strncat_in_locale(struct archive_string *as, const void *_p, archive_string_append(as, _p, length); /* If charset is NULL, just make a copy, so return 0 as success. */ - if (sc == NULL || (sc->same && invalid_mbs(_p, n, sc) == 0)) + if (sc == NULL || (sc->same && invalid_mbs(_p, length, sc) == 0)) return (0); if (is_all_ascii_code(as)) return (0);