Merge pull request #218 from jpoliv/master

Fixes a couple of compiler warnings
This commit is contained in:
Bob
2013-10-15 15:20:53 -07:00
2 changed files with 7 additions and 2 deletions
+2
View File
@@ -12,6 +12,8 @@ MANDIR = /usr/share/man/man1
DOCDIRS = doc/html doc/latex DOCDIRS = doc/html doc/latex
PDF = doc/latex/refman.pdf PDF = doc/latex/refman.pdf
CFLAGS += -Wall -Wextra
all: codecheck test all: codecheck test
clean: clean:
+5 -2
View File
@@ -13,6 +13,7 @@
* Partially based on public domain setsid(1) * Partially based on public domain setsid(1)
*/ */
#define _GNU_SOURCE
#include <stdio.h> #include <stdio.h>
#include <linux/sched.h> #include <linux/sched.h>
#include <unistd.h> #include <unistd.h>
@@ -20,8 +21,8 @@
#include <syscall.h> #include <syscall.h>
#include <fcntl.h> #include <fcntl.h>
#include <stdlib.h> #include <stdlib.h>
#include <limits.h>
#include <sched.h> #include <sched.h>
#include <ctype.h>
#if !defined(VERSION) #if !defined(VERSION)
#define VERSION "(devel)" #define VERSION "(devel)"
@@ -62,7 +63,7 @@ void validate(char *path)
} }
/* Add our pid to cgroup */ /* Add our pid to cgroup */
int cgroup(char *gname) void cgroup(char *gname)
{ {
static char path[PATH_MAX]; static char path[PATH_MAX];
static char *groups[] = { static char *groups[] = {
@@ -176,4 +177,6 @@ int main(int argc, char *argv[])
} }
usage(argv[0]); usage(argv[0]);
return 0;
} }