sock: Error out if setting of the system socket memory fails
commite0a7ae85351de7ebc43af1fe5f04e650c6736201
authorTobias Klauser <tklauser@distanz.ch>
Tue, 9 Sep 2014 12:34:38 +0000 (9 14:34 +0200)
committerTobias Klauser <tklauser@distanz.ch>
Tue, 9 Sep 2014 12:34:38 +0000 (9 14:34 +0200)
treedba82b8cd3e91b864f4c112ab42b5065e43a5aa7
parent83db3213e55a646132e092014e162ebfe16b7236
sock: Error out if setting of the system socket memory fails

Currently we ignore the return value of the write() calls to
/proc/sys/net/core/{r,w}mem_{default,max} in set_system_socket_mem().
Better check the return value and notify the user about it.

This also fixes a clang compiler warning about a variable explicitely
assigned to itself.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
sock.c