udscs: The read buffer is always reset to NULL
commitc943d0b6b2b25aa0e69857ae5e1f987d0010a169
authorFrancois Gouget <fgouget@codeweavers.com>
Mon, 28 Nov 2016 08:40:56 +0000 (28 09:40 +0100)
committerChristophe Fergeau <cfergeau@redhat.com>
Mon, 28 Nov 2016 09:54:56 +0000 (28 10:54 +0100)
treeb4b319d0c4428fbc9669e53d3ce7159f119d8b56
parent7324da13b848498ed8c849310addcef497ed4cd5
udscs: The read buffer is always reset to NULL

Tweak the code to clarify that conn->data.buf is set to NULL after the
free() in udscs_read_complete().
Note that this reset is needed to avoid a double-free in
udscs_destroy_connection() if an error occurs while receiving
the next message header.

Signed-off-by: Francois Gouget <fgouget@codeweavers.com>
src/udscs.c