#7 Defect: Coverity incorrect return check
Closed: Fixed Opened by firstyear.

  1. svrcore-4.1.0/src/systemd-ask-pass.c:241: returned_null: "fopen" returns null.
  2. svrcore-4.1.0/src/systemd-ask-pass.c:241: var_assigned: Assigning: "tmp_fd" = null return value from "fopen".
  3. svrcore-4.1.0/src/systemd-ask-pass.c:246: dereference: Dereferencing a pointer that might be null "tmp_fd" when calling "fprintf". [Note: The source code implementation of the function has been overridden by a builtin model.]

244| // Write data to the file

245| // [Ask]

246|-> fprintf(tmp_fd, "[Ask]\n");

247| // PID=Our Pid

248| fprintf(tmp_fd, "PID=%d\n", pid);


PR#11

Metadata