diff options
author | Christian Beier <dontmind@freeshell.org> | 2012-05-09 17:31:59 +0200 |
---|---|---|
committer | Christian Beier <dontmind@freeshell.org> | 2012-05-09 17:31:59 +0200 |
commit | 2a97ab8679157c629e67b966d16ee86a0b6c2d90 (patch) | |
tree | a7143859bc338c4405a2fa5fd9c48be248760226 /libvncclient/rfbproto.c | |
parent | ab74d36dcde455308e42a4117e03ee89b8800886 (diff) | |
download | libtdevnc-2a97ab8679157c629e67b966d16ee86a0b6c2d90.tar.gz libtdevnc-2a97ab8679157c629e67b966d16ee86a0b6c2d90.zip |
Fix some compiler warnings that hinted some no too unimportant errors.
Diffstat (limited to 'libvncclient/rfbproto.c')
-rw-r--r-- | libvncclient/rfbproto.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libvncclient/rfbproto.c b/libvncclient/rfbproto.c index 8064b56..505ef50 100644 --- a/libvncclient/rfbproto.c +++ b/libvncclient/rfbproto.c @@ -387,8 +387,8 @@ ConnectToRFBServer(rfbClient* client,const char *hostname, int port) return FALSE; } setbuf(rec->file,NULL); - fread(buffer,1,strlen(magic),rec->file); - if (strncmp(buffer,magic,strlen(magic))) { + + if (fread(buffer,1,strlen(magic),rec->file) != strlen(magic) || strncmp(buffer,magic,strlen(magic))) { rfbClientLog("File %s was not recorded by vncrec.\n",client->serverHost); fclose(rec->file); return FALSE; |