aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index 53fd0b2..5530bf7 100644
--- a/src/main.c
+++ b/src/main.c
@@ -17,9 +17,15 @@ int main(int argc, char **argv) {
if ((str = malloc(n + 1)) == NULL) {
perror("main: malloc failed");
exit(EXIT_FAILURE);
- }
-
+ }
+
+ strcpy(str, argv[0]);
+ for (int i = 1; i < argc; i++)
+ strcat(str, argv[i]);
+
syslog(LOG_DEBUG, "args: %s\n", str);
+ free(str);
+
return 0;
}