OSDN Git Service
(root)
/
android-x86
/
external-bluetooth-bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ce632ba
)
sdp: Check correct number of bytes received in recv
author
Andrei Emeltchenko
<andrei.emeltchenko@intel.com>
Tue, 17 Sep 2013 14:40:20 +0000
(17:40 +0300)
committer
Johan Hedberg
<johan.hedberg@intel.com>
Thu, 19 Sep 2013 03:09:52 +0000
(22:09 -0500)
Instead of checking for error check that correct number of bytes received.
src/sdpd-server.c
patch
|
blob
|
history
diff --git
a/src/sdpd-server.c
b/src/sdpd-server.c
index
181d248
..
7b1351f
100644
(file)
--- a/
src/sdpd-server.c
+++ b/
src/sdpd-server.c
@@
-177,7
+177,7
@@
static gboolean io_session_event(GIOChannel *chan, GIOCondition cond, gpointer d
return TRUE;
len = recv(sk, buf, size, 0);
- if (len
<= 0
) {
+ if (len
!= size
) {
sdp_svcdb_collect_all(sk);
free(buf);
return FALSE;