diff options
author | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2019-05-07 15:58:02 +0200 |
---|---|---|
committer | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2019-07-24 16:25:58 +0200 |
commit | a9d6acc088be7d5e027531b7377f25850aab02b3 (patch) | |
tree | 165007fcfe9371d9a8d939a28393e6477b8b69df | |
parent | 7f71d66c3d3151e2b9dc7daa7e2793222cacaaec (diff) | |
download | hardware_replicant_libsamsung-ril-a9d6acc088be7d5e027531b7377f25850aab02b3.tar.gz hardware_replicant_libsamsung-ril-a9d6acc088be7d5e027531b7377f25850aab02b3.tar.bz2 hardware_replicant_libsamsung-ril-a9d6acc088be7d5e027531b7377f25850aab02b3.zip |
client: Fix warning about array comparison to a null pointer
Without that fix we have:
client.c:32:6: error: comparison of array
'ril_clients' equal to a null pointer is always
false [-Werror,-Wtautological-pointer-compare]
if (ril_clients == NULL || ril_clients_count == 0)
^~~~~~~~~~~ ~~~~
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
Reviewed-by: Joonas Kylmälä <joonas.kylmala@iki.fi>
-rw-r--r-- | client.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -29,7 +29,7 @@ struct ril_client *ril_client_find_id(int id) { unsigned int i; - if (ril_clients == NULL || ril_clients_count == 0) + if (ril_clients_count == 0) return NULL; for (i = 0; i < ril_clients_count; i++) { |