From: John Levon Date: Sun, 1 Aug 2021 17:53:25 +0000 (+0100) Subject: test: quieten warning noise while forking X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=b13da15ec254bd414eca7704c809f977bc4d18d5;p=dpdk.git test: quieten warning noise while forking When closing file descriptors post-fork, ignore "." and ".." directory entries, so the test log doesn't have distracting errors like: Error converting name fd 0 .: Error converting name fd 0 ..: Signed-off-by: John Levon --- diff --git a/app/test/process.h b/app/test/process.h index 0ed91a939e..5b10cf64df 100644 --- a/app/test/process.h +++ b/app/test/process.h @@ -90,6 +90,11 @@ process_dup(const char *const argv[], int numargs, const char *env_value) } while ((dirent = readdir(dir)) != NULL) { + + if (strcmp(dirent->d_name, ".") == 0 || + strcmp(dirent->d_name, "..") == 0) + continue; + errno = 0; fd = strtol(dirent->d_name, &endptr, 10); if (errno != 0 || endptr[0] != '\0') {