diff options
author | Karel Zak | 2013-05-29 10:56:05 +0200 |
---|---|---|
committer | Karel Zak | 2013-05-29 10:56:05 +0200 |
commit | 195c36032a313ffdc823d3a3a887fc56d31619b9 (patch) | |
tree | f34b6b5266417ed00af2c444af5c316fb7d72b99 /misc-utils | |
parent | logger: cleanup usage() (diff) | |
download | kernel-qcow2-util-linux-195c36032a313ffdc823d3a3a887fc56d31619b9.tar.gz kernel-qcow2-util-linux-195c36032a313ffdc823d3a3a887fc56d31619b9.tar.xz kernel-qcow2-util-linux-195c36032a313ffdc823d3a3a887fc56d31619b9.zip |
logger: small coding style changes
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'misc-utils')
-rw-r--r-- | misc-utils/logger.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/misc-utils/logger.c b/misc-utils/logger.c index 75f0c8c2a..161a7aa1b 100644 --- a/misc-utils/logger.c +++ b/misc-utils/logger.c @@ -125,8 +125,7 @@ static int pencode(char *s) return ((lev & LOG_PRIMASK) | (fac & LOG_FACMASK)); } -static int -unix_socket(const char *path, const int socket_type) +static int unix_socket(const char *path, const int socket_type) { int fd, i; static struct sockaddr_un s_addr; /* AF_UNIX address of local logger */ @@ -159,8 +158,8 @@ unix_socket(const char *path, const int socket_type) return fd; } -static int -inet_socket(const char *servername, const char *port, const int socket_type) +static int inet_socket(const char *servername, const char *port, + const int socket_type) { int fd, errcode, i; struct addrinfo hints, *res; @@ -205,8 +204,8 @@ inet_socket(const char *servername, const char *port, const int socket_type) return fd; } -static void -mysyslog(int fd, int logflags, int pri, char *tag, char *msg) { +static void mysyslog(int fd, int logflags, int pri, char *tag, char *msg) +{ char buf[1000], pid[30], *cp, *tp; time_t now; @@ -265,8 +264,8 @@ static void __attribute__ ((__noreturn__)) usage(FILE *out) * Reads from an input and arranges to write the result on the system * log. */ -int -main(int argc, char **argv) { +int main(int argc, char **argv) +{ int ch, logflags, pri, prio_prefix; char *tag, buf[1024]; char *usock = NULL; |