From 02d71a88ab0794799a40f8d08240d73028176815 Mon Sep 17 00:00:00 2001 From: Luca Boccassi Date: Wed, 13 Apr 2016 00:05:26 +0100 Subject: [PATCH] Problem: missing () after sizeof cause build fail Solution: use sizeof () to avoid build failure on Solaris 10 with gcc 3.4 --- src/tcp_address.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tcp_address.cpp b/src/tcp_address.cpp index 0c699e3a..86fa617f 100644 --- a/src/tcp_address.cpp +++ b/src/tcp_address.cpp @@ -86,7 +86,7 @@ int zmq::tcp_address_t::resolve_nic_name (const char *nic_, bool ipv6_, bool is_ // Find the interface with the specified name and AF_INET family. bool found = false; lifreq *ifrp = ifc.lifc_req; - for (int n = 0; n < (int) (ifc.lifc_len / sizeof lifreq); + for (int n = 0; n < (int) (ifc.lifc_len / sizeof (lifreq)); n ++, ifrp ++) { if (!strcmp (nic_, ifrp->lifr_name)) { rc = ioctl (fd, SIOCGLIFADDR, (char*) ifrp);