diff options
Diffstat (limited to 'mixlib/mix_src_file.c')
-rw-r--r-- | mixlib/mix_src_file.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/mixlib/mix_src_file.c b/mixlib/mix_src_file.c index 1cb6656..4e1489b 100644 --- a/mixlib/mix_src_file.c +++ b/mixlib/mix_src_file.c @@ -1,7 +1,7 @@ /* -*-c-*- -------------- mix_src_file.c : * Implementation of the functions declared in mix_src_file.h * ------------------------------------------------------------------ - * Last change: Time-stamp: "01/03/10 03:25:50 jose" + * Last change: Time-stamp: "01/03/10 15:23:46 jose" * ------------------------------------------------------------------ * Copyright (C) 2000, 2001 Free Software Foundation, Inc. * @@ -22,6 +22,7 @@ */ #include <ctype.h> +#include <string.h> #include <stdio.h> #include <unistd.h> #include "mix_src_file.h" @@ -42,8 +43,8 @@ format_line_ (gchar *line) gint k = 0; if (!line) return line; - if (line[0] == '*' || strlen(line) == 0) return g_strdup (line); - + if (line[0] == '*' || strlen(line) == 0) + return g_strdup (line); if (isspace (line[0])) { @@ -64,15 +65,15 @@ format_line_ (gchar *line) while (line[k] && !isspace (line[k])) ++k; while (line[k] && isspace (line[k])) ++k; line[k - 1] = 0; - rest = (line[k]) ? line + k: "\n"; + rest = (line[k]) ? line + k: ""; } else { - op = rest = "\n"; + op = rest = ""; } - return g_strdup_printf ("%-12s%-6s%s", label, op, rest); + return g_strdup_printf ("%-11s %-5s %s", label, op, rest); } /* load the source file lines into memory */ |