• R/O
  • SSH
  • HTTPS

scip: Commit


Commit MetaInfo

Revision21 (tree)
Time2008-10-26 17:10:20
Authory_o_s

Log Message

scipIOPoll の戻り値チェックがおかしいのを修正
Thanks KIY

Change Summary

Incremental Difference

--- libscip2/trunk/src/scipio-linux.c (revision 20)
+++ libscip2/trunk/src/scipio-linux.c (revision 21)
@@ -142,14 +142,14 @@
142142 */
143143 int scipIORead(tScipIO aDev, void *aBuff, size_t aCount, int aTimeoutMs)
144144 {
145- if(scipIOPoll(aDev,aTimeoutMs)==0)
146- {
147- int ret=read(aDev->fd,aBuff,aCount);
148- if(ret==-1)
149- return errno;
150- return ret;
151- }
152- return 0;
145+ int ret;
146+ ret=scipIOPoll(aDev,aTimeoutMs);
147+ if(ret<=0)
148+ return ret;
149+ ret=read(aDev->fd,aBuff,aCount);
150+ if(ret==-1)
151+ return errno;
152+ return ret;
153153 }
154154
155155 // ReadLine 用ユーティリティ
Show on old repository browser