Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 06c6589b authored by Dima Zavin's avatar Dima Zavin Committed by The Android Open Source Project
Browse files

am 770354d7: init: Fix segfault when log_write() was missing an arg to fo

Merge commit '770354d7'

* commit '770354d7':
  init: Fix segfault when log_write() was missing an arg to format.
parents 9b317447 770354d7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -423,7 +423,7 @@ static void msg_stop(const char *name)
    if (svc) {
        service_stop(svc);
    } else {
        ERROR("no such service '%s'\n");
        ERROR("no such service '%s'\n", name);
    }
}

+2 −1
Original line number Diff line number Diff line
@@ -29,7 +29,8 @@ void *read_file(const char *fn, unsigned *_sz);
void log_init(void);
void log_set_level(int level);
void log_close(void);
void log_write(int level, const char *fmt, ...);
void log_write(int level, const char *fmt, ...)
    __attribute__ ((format(printf, 2, 3)));

#define ERROR(x...)   log_write(3, "<3>init: " x)
#define NOTICE(x...)  log_write(5, "<5>init: " x)