policycoreutils: restorecond: Stop using deprecated interfaces for g_io

g_io_channel_read is deprecated.  Use g_io_channel_read_chars instead.

Signed-off-by: Eric Paris <eparis@redhat.com>
This commit is contained in:
Dan Walsh 2012-01-24 11:24:37 -05:00 committed by Eric Paris
parent d4064c954f
commit 137604222a
1 changed files with 3 additions and 3 deletions

View File

@ -118,10 +118,10 @@ io_channel_callback
if (condition & G_IO_IN) { if (condition & G_IO_IN) {
/* Data is available. */ /* Data is available. */
g_io_channel_read g_io_channel_read_chars
(source, buffer, (source, buffer,
sizeof (buffer), sizeof (buffer),
&bytes_read); &bytes_read, NULL);
if (! bytes_read) { if (! bytes_read) {
/* Sesssion/Terminal Ended */ /* Sesssion/Terminal Ended */
@ -152,7 +152,7 @@ io_channel_callback
file. */ file. */
if (condition & G_IO_HUP) { if (condition & G_IO_HUP) {
g_io_channel_close (source); g_io_channel_shutdown (source, 0, NULL);
exit(0); exit(0);
return FALSE; return FALSE;
} }