On Thu, Apr 13, 2017 at 09:33:06AM +0800, JingPiao Chen wrote: > On Thu, Apr 13, 2017 at 5:10 AM, Dmitry V. Levin wrote: > >On Wed, Apr 12, 2017 at 09:31:51PM +0800, JingPiao Chen wrote: > >> @@ -198,6 +199,48 @@ qualify_syscall_number(const char *s, struct > number_set *set) > >> return done; > >> } > >> > >> +static bool > >> +qualify_syscall_regex(const char *s, struct number_set *set) > >> +{ > >> + regex_t preg; > >> + int rc; > >> + > >> + if ((rc = regcomp(&preg, s, REG_EXTENDED | REG_NOSUB)) != 0) { > >> + size_t len = regerror(rc, &preg, NULL, 0); > >> + char buf[len]; > > > >We don't use VLA on the stack, it is not portable. In particular, > >it won't pass travis-ci clang tests. If you've pushed it to github > >and enabled travis-ci, you'd have noticed. > > Ok, I replace it with alloca. But it pass travis-ci clang tests [1],
Well, I'm surprised. > and strace have similar code in socketutils.c:152. It's not quite similar, there are two constant values there. -- ldv
signature.asc
Description: PGP signature
------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________ Strace-devel mailing list Strace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/strace-devel