[gtk+] Fix a compilation warning



commit 33f53e1d0460b26f5dd4713555cc553dbef4847a
Author: Javier Jardón <jjardon gnome org>
Date:   Tue Oct 20 20:43:44 2009 +0200

    Fix a compilation warning
    
    Catch the returned value of write()

 modules/other/gail/tests/ferret.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/modules/other/gail/tests/ferret.c b/modules/other/gail/tests/ferret.c
index 14281de..531651b 100644
--- a/modules/other/gail/tests/ferret.c
+++ b/modules/other/gail/tests/ferret.c
@@ -429,11 +429,14 @@ static void _send_to_festival (const gchar *role_name,
 
 static void _festival_write (const gchar *command_string, int fd)
 {
+  gssize n_bytes;
+
   if (fd < 0) {
     perror("socket");
     return;
   }
-  write(fd, command_string, strlen(command_string));
+  n_bytes = write(fd, command_string, strlen(command_string));
+  g_assert (n_bytes == strlen(command_string));
 }
 
 static void _speak_caret_event (AtkObject *aobject)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]