diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2018-12-02 05:58:18 +0100 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2018-12-02 05:58:18 +0100 |
commit | cedfe0b02b3cab6281106a6f4e090336b3ca487f (patch) | |
tree | 4e8f7b8cb8c128c9d56951aad56594b564edab6b /src/shared/ip-protocol-list.c | |
parent | util: rename socket_protocol_{from,to}_name() to ip_protocol_{from,to}_name() (diff) | |
download | systemd-cedfe0b02b3cab6281106a6f4e090336b3ca487f.tar.xz systemd-cedfe0b02b3cab6281106a6f4e090336b3ca487f.zip |
util: cast smaller type to large type
Diffstat (limited to 'src/shared/ip-protocol-list.c')
-rw-r--r-- | src/shared/ip-protocol-list.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/ip-protocol-list.c b/src/shared/ip-protocol-list.c index 9a1c11b0d8..775cd3313d 100644 --- a/src/shared/ip-protocol-list.c +++ b/src/shared/ip-protocol-list.c @@ -17,7 +17,7 @@ const char *ip_protocol_to_name(int id) { if (id < 0) return NULL; - if (id >= (int) ELEMENTSOF(ip_protocol_names)) + if ((size_t) id >= ELEMENTSOF(ip_protocol_names)) return NULL; return ip_protocol_names[id]; |