aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/io.c
diff options
context:
space:
mode:
authorGravatar Brendan Taylor <whateley@gmail.com>2011-02-14 22:51:46 -0700
committerGravatar Brendan Taylor <whateley@gmail.com>2011-02-14 22:54:54 -0700
commitdb3984b609153ff213233f1a78c8895fdb525350 (patch)
tree24e6b2959d08b8cadb93853cb3620681f6f05e64 /src/io.c
parent59af2a8499160a369aceed1bd5cb32109fb5e77c (diff)
parent700332fac498169927ced24731ce1278369b1425 (diff)
Merge branch 'experimental' into cleaning-commenting
Conflicts: src/callbacks.c src/uzbl-core.c src/uzbl-core.h
Diffstat (limited to 'src/io.c')
-rw-r--r--src/io.c20
1 files changed, 6 insertions, 14 deletions
diff --git a/src/io.c b/src/io.c
index 1c463db..1e85237 100644
--- a/src/io.c
+++ b/src/io.c
@@ -129,27 +129,20 @@ control_stdin(GIOChannel *gio, GIOCondition condition) {
return TRUE;
}
-
void
-create_stdin () {
- GIOChannel *chan = NULL;
- GError *error = NULL;
-
- chan = g_io_channel_unix_new(fileno(stdin));
+create_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
remove_socket_from_array(GIOChannel *chan) {
gboolean ret = 0;
@@ -163,7 +156,6 @@ remove_socket_from_array(GIOChannel *chan) {
return ret;
}
-
gboolean
control_socket(GIOChannel *chan) {
struct sockaddr_un remote;