changeset 5196:aed5971d73a8

A bug fix + moved error msg from verbose to error
author albeu
date Tue, 19 Mar 2002 13:28:45 +0000
parents 3a0d9f577c45
children f0e3dcefb7af
files input/lirc.c
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/input/lirc.c	Tue Mar 19 13:27:44 2002 +0000
+++ b/input/lirc.c	Tue Mar 19 13:28:45 2002 +0000
@@ -103,11 +103,11 @@
       strcpy(buf,cmd);
       buf[len-1] = '\n';
       while(w < len) {
-	int r = write(mp_fd,buf,len-w);
+	int r = write(mp_fd,buf+w,len-w);
 	if(r < 0) {
 	  if(errno == EINTR)
 	    continue;
-	  mp_msg(MSGT_LIRC,MSGL_V,"LIRC subprocess can't write in input pipe : %s\n",
+	  mp_msg(MSGT_LIRC,MSGL_ERR,"LIRC subprocess can't write in input pipe : %s\n",
 		 strerror(errno));
 	  mp_input_lirc_process_quit(-1);
 	}
@@ -126,13 +126,13 @@
   if(child_pid <= 0)
     return;
   if( kill(child_pid,SIGQUIT) != 0) {
-    mp_msg(MSGT_LIRC,MSGL_V,"LIRC can't kill subprocess %d : %s\n",
+    mp_msg(MSGT_LIRC,MSGL_ERR,"LIRC can't kill subprocess %d : %s\n",
 	   child_pid,strerror(errno));
     return;
   }
 
   if(waitpid(child_pid,NULL,0) < 0)
-    mp_msg(MSGT_LIRC,MSGL_V,"LIRC error while waiting subprocess %d : %s\n",
+    mp_msg(MSGT_LIRC,MSGL_ERR,"LIRC error while waiting subprocess %d : %s\n",
 	   child_pid,strerror(errno));
 
 }