diff options
author | Joaquín Ignacio Aramendía <[email protected]> | 2014-06-25 19:06:17 -0300 |
---|---|---|
committer | Joaquín Ignacio Aramendía <[email protected]> | 2014-06-26 20:03:32 -0300 |
commit | a65a66d49bd0d6ec6c94b8e3ecd551cb570cec95 (patch) | |
tree | b451afa6025e587f0ee287601427e572712e3428 /src/core/util.c | |
parent | 32050fd47713d9254e05344a6afd87202fa45d11 (diff) | |
download | marco-a65a66d49bd0d6ec6c94b8e3ecd551cb570cec95.tar.bz2 marco-a65a66d49bd0d6ec6c94b8e3ecd551cb570cec95.tar.xz |
Remove all trailing whitespaces in the code tree
Just run:
$ find -name '*.c' -print0 | xargs -r0 sed -e 's/[[:blank:]]\+$//' -i
$ find -name '*.h' -print0 | xargs -r0 sed -e 's/[[:blank:]]\+$//' -i
Diffstat (limited to 'src/core/util.c')
-rw-r--r-- | src/core/util.c | 76 |
1 files changed, 38 insertions, 38 deletions
diff --git a/src/core/util.c b/src/core/util.c index ac721009..b3239976 100644 --- a/src/core/util.c +++ b/src/core/util.c @@ -2,10 +2,10 @@ /* Marco utilities */ -/* +/* * Copyright (C) 2001 Havoc Pennington * Copyright (C) 2005 Elijah Newren - * + * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of the @@ -15,7 +15,7 @@ * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA @@ -46,11 +46,11 @@ meta_print_backtrace (void) int bt_size; int i; char **syms; - + bt_size = backtrace (bt, 500); syms = backtrace_symbols (bt, bt_size); - + i = 0; while (i < bt_size) { @@ -85,7 +85,7 @@ ensure_logfile (void) char *tmpl; int fd; GError *err; - + tmpl = g_strdup_printf ("marco-%d-debug-log-XXXXXX", (int) getpid ()); @@ -95,7 +95,7 @@ ensure_logfile (void) &err); g_free (tmpl); - + if (err != NULL) { meta_warning (_("Failed to open debug log: %s\n"), @@ -103,9 +103,9 @@ ensure_logfile (void) g_error_free (err); return; } - + logfile = fdopen (fd, "w"); - + if (logfile == NULL) { meta_warning (_("Failed to fdopen() log file %s: %s\n"), @@ -116,7 +116,7 @@ ensure_logfile (void) { g_printerr (_("Opened log file %s\n"), filename); } - + g_free (filename); } } @@ -134,11 +134,11 @@ meta_set_verbose (gboolean setting) #ifndef WITH_VERBOSE_MODE if (setting) meta_fatal (_("Marco was compiled without support for verbose mode\n")); -#else +#else if (setting) ensure_logfile (); #endif - + is_verbose = setting; } @@ -191,7 +191,7 @@ utf8_fputs (const char *str, { char *l; int retval; - + l = g_locale_from_utf8 (str, -1, NULL, NULL, NULL); if (l == NULL) @@ -220,24 +220,24 @@ meta_debug_spew_real (const char *format, ...) va_list args; gchar *str; FILE *out; - + g_return_if_fail (format != NULL); if (!is_debugging) return; - + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); out = logfile ? logfile : stderr; - + if (no_prefix == 0) utf8_fputs (_("Window manager: "), out); utf8_fputs (str, out); fflush (out); - + g_free (str); } #endif /* WITH_VERBOSE_MODE */ @@ -254,19 +254,19 @@ meta_verbose_real (const char *format, ...) if (!is_verbose) return; - + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); out = logfile ? logfile : stderr; - + if (no_prefix == 0) utf8_fputs ("Window manager: ", out); utf8_fputs (str, out); fflush (out); - + g_free (str); } #endif /* WITH_VERBOSE_MODE */ @@ -341,8 +341,8 @@ meta_topic_real (MetaDebugTopic topic, if (!is_verbose) return; - - va_start (args, format); + + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); @@ -356,11 +356,11 @@ meta_topic_real (MetaDebugTopic topic, ++sync_count; fprintf (out, "%d: ", sync_count); } - + utf8_fputs (str, out); - + fflush (out); - + g_free (str); } #endif /* WITH_VERBOSE_MODE */ @@ -373,7 +373,7 @@ meta_bug (const char *format, ...) FILE *out; g_return_if_fail (format != NULL); - + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); @@ -389,11 +389,11 @@ meta_bug (const char *format, ...) utf8_fputs (str, out); fflush (out); - + g_free (str); meta_print_backtrace (); - + /* stop us in a debugger */ abort (); } @@ -404,9 +404,9 @@ meta_warning (const char *format, ...) va_list args; gchar *str; FILE *out; - + g_return_if_fail (format != NULL); - + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); @@ -422,7 +422,7 @@ meta_warning (const char *format, ...) utf8_fputs (str, out); fflush (out); - + g_free (str); } @@ -432,9 +432,9 @@ meta_fatal (const char *format, ...) va_list args; gchar *str; FILE *out; - + g_return_if_fail (format != NULL); - + va_start (args, format); str = g_strdup_vprintf (format, args); va_end (args); @@ -450,7 +450,7 @@ meta_fatal (const char *format, ...) utf8_fputs (str, out); fflush (out); - + g_free (str); meta_exit (META_EXIT_ERROR); @@ -473,7 +473,7 @@ meta_pop_no_msg_prefix (void) void meta_exit (MetaExitCode code) { - + exit (code); } @@ -570,7 +570,7 @@ meta_show_dialog (const char *type, argvl[i++] = _("Marco"); argvl[i++] = "--text"; argvl[i++] = message; - + if (timeout) { argvl[i++] = "--timeout"; @@ -588,7 +588,7 @@ meta_show_dialog (const char *type, argvl[i++] = "--cancel-label"; argvl[i++] = cancel_text; } - + tmp = columns; while (tmp) { @@ -603,7 +603,7 @@ meta_show_dialog (const char *type, argvl[i++] = tmp->data; tmp = tmp->next; } - + argvl[i] = NULL; if (transient_for) |