[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 1/3] qemu-bridge-helper: restrict interface n
From: |
P J P |
Subject: |
Re: [Qemu-devel] [PATCH v2 1/3] qemu-bridge-helper: restrict interface name to IFNAMSIZ |
Date: |
Mon, 1 Jul 2019 15:28:30 +0530 (IST) |
+-- On Mon, 1 Jul 2019, Daniel P. Berrangé wrote --+
| > + if (strcmp(cmd, "include") && strlen(arg) >= IFNAMSIZ) {
| > + fprintf(stderr, "name `%s' too long: %lu\n", arg, strlen(arg));
|
| strlen returns size_t, which does not match %lu - it needs %zu - we can
| ignore the non-portability of %zu to windows, since this code is UNIX
| only.
|
| I'd prefer also !g_str_equal(cmd, "include") as to me it reads more
| easily.
Okay. Thank you.
--
Prasad J Pandit / Red Hat Product Security Team
47AF CE69 3A90 54AA 9045 1053 DD13 3D32 FE5B 041F
- [Qemu-devel] [PATCH v2 0/3] restrict bridge interface name to IFNAMSIZ, P J P, 2019/07/01
- [Qemu-devel] [PATCH v2 1/3] qemu-bridge-helper: restrict interface name to IFNAMSIZ, P J P, 2019/07/01
- [Qemu-devel] [PATCH v2 3/3] net: tap: restrict bridge name to IFNAMSIZ, P J P, 2019/07/01
- [Qemu-devel] [PATCH v2 2/3] qemu-bridge-helper: move repeating code in parse_acl_file, P J P, 2019/07/01
- Re: [Qemu-devel] [PATCH v2 0/3] restrict bridge interface name to IFNAMSIZ, no-reply, 2019/07/01
- Re: [Qemu-devel] [PATCH v2 0/3] restrict bridge interface name to IFNAMSIZ, no-reply, 2019/07/01