diff options
author | Sven Eckelmann <sven@narfation.org> | 2012-05-05 13:27:28 +0200 |
---|---|---|
committer | Antonio Quartulli <ordex@autistici.org> | 2012-06-18 18:01:03 +0200 |
commit | 5346c35ebfbdb1727e60079456dd8071cb888059 (patch) | |
tree | 90bba36cd5e27b1a248cf78d4a4859b6d7275092 /net/batman-adv/icmp_socket.c | |
parent | e0f5211f9bbfaa66d27cda6b0dc86466c7dcb206 (diff) |
batman-adv: Return error codes instead of -1 on failures
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Diffstat (limited to 'net/batman-adv/icmp_socket.c')
-rw-r--r-- | net/batman-adv/icmp_socket.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/batman-adv/icmp_socket.c b/net/batman-adv/icmp_socket.c index 2e98a57f3407..d27db8192e93 100644 --- a/net/batman-adv/icmp_socket.c +++ b/net/batman-adv/icmp_socket.c @@ -285,13 +285,13 @@ int bat_socket_setup(struct bat_priv *bat_priv) d = debugfs_create_file(ICMP_SOCKET, S_IFREG | S_IWUSR | S_IRUSR, bat_priv->debug_dir, bat_priv, &fops); - if (d) + if (!d) goto err; return 0; err: - return 1; + return -ENOMEM; } static void bat_socket_add_packet(struct socket_client *socket_client, |