chiark / gitweb /
install: introduce new DefaultInstance= field for [Install] sections
[elogind.git] / src / core / killall.c
index 7664775142dbd2a98539eca12b8642d1fb17a419..eab48f7dcabdc9475a788b7bcd46256bb1ac614a 100644 (file)
@@ -33,7 +33,8 @@
 
 static bool ignore_proc(pid_t pid) {
         _cleanup_fclose_ FILE *f = NULL;
-        char c, *p;
+        char c;
+        const char *p;
         size_t count;
         uid_t uid;
         int r;
@@ -167,7 +168,7 @@ static int killall(int sig, Set *pids, bool send_sighup) {
                         continue;
 
                 if (sig == SIGKILL) {
-                        _cleanup_free_ char *s;
+                        _cleanup_free_ char *s = NULL;
 
                         get_process_comm(pid, &s);
                         log_notice("Sending SIGKILL to PID "PID_FMT" (%s).", pid, strna(s));