From db134de3b9cefa6e0d76fe57f2feabe79ba9216c Mon Sep 17 00:00:00 2001 From: Ulrich Sibiller Date: Mon, 4 Jan 2021 16:17:36 +0100 Subject: Atoms.c: add explanation for PVS Studio warning "V575 The potential null pointer is passed into 'strlen' function. Inspect the first argument. Check lines: 420, 403." --- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'nx-X11') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 61953e2a6..ea7ad7599 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -409,6 +409,9 @@ static void nxagentWriteAtom(Atom local, XlibAtom remote, const char *string) #ifdef WARNING if (s == NULL) { + /* we only warn here, because s being NULL ist not problem, it + will only result in NULL being stored in the privAtomMap, which + is perfectly legal. */ fprintf(stderr, "%s: Malloc failed.\n", __func__); } #endif -- cgit v1.2.3