From: Dmitry V. Levin Date: Mon, 24 Dec 2018 10:19:24 +0000 (+0000) Subject: xlat_idx: do not issue warnings for holes in indices X-Git-Tag: v4.26~30 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b967e34d70895b799d16f5d45a9a5228d7eb73a3;p=strace xlat_idx: do not issue warnings for holes in indices Some xlat indices like evdev_abs have holes, avoid issuing warnings about them. * xlat.c (xlat_idx): Do not issue warnings for holes in the index. --- diff --git a/xlat.c b/xlat.c index 16bfb94d..62245f9c 100644 --- a/xlat.c +++ b/xlat.c @@ -249,6 +249,9 @@ xlat_idx(const struct xlat *xlat, size_t nmemb, uint64_t val) return NULL; if (val != pos[val].val) { + if (pos[val].val == 0) + return NULL; /* a hole in the index */ + error_func_msg("Unexpected xlat value %" PRIu64 " at index %" PRIu64, pos[val].val, val);