diff options
author | Brendan Taylor <whateley@gmail.com> | 2011-02-14 21:22:18 -0700 |
---|---|---|
committer | Brendan Taylor <whateley@gmail.com> | 2011-02-14 21:22:18 -0700 |
commit | 9157a5aecfe16edfc1b238e43f50a61c1a174ee3 (patch) | |
tree | 65f9f6ed97c1bb5e764887d35379eb3f21305087 /src | |
parent | 8ae529244eeefa13b43a08593eedf80cf6d3a2b3 (diff) | |
parent | 113853220d5d99720c448c76474c91fc283ea4e5 (diff) |
Merge branch 'static-analysis' into experimental
Diffstat (limited to 'src')
-rw-r--r-- | src/uzbl-core.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/src/uzbl-core.c b/src/uzbl-core.c index 877dbda..b45a5ae 100644 --- a/src/uzbl-core.c +++ b/src/uzbl-core.c @@ -1623,21 +1623,16 @@ control_stdin(GIOChannel *gio, GIOCondition condition) { void create_stdin () { - GIOChannel *chan = NULL; - GError *error = NULL; - - chan = g_io_channel_unix_new(fileno(stdin)); + GIOChannel *chan = g_io_channel_unix_new(fileno(stdin)); if (chan) { if (!g_io_add_watch(chan, G_IO_IN|G_IO_HUP, (GIOFunc) control_stdin, NULL)) { - g_error ("Stdin: could not add watch\n"); - } else { - if (uzbl.state.verbose) - printf ("Stdin: watch added successfully\n"); + g_error ("create_stdin: could not add watch\n"); + } else if (uzbl.state.verbose) { + printf ("create_stdin: watch added successfully\n"); } } else { - g_error ("Stdin: Error while opening: %s\n", error->message); + g_error ("create_stdin: error while opening stdin\n"); } - if (error) g_error_free (error); } gboolean |