Bug 1156 - opt build ‘result’ set but not used, g++ > 4.6.0
opt build ‘result’ set but not used, g++ > 4.6.0
Status: RESOLVED FIXED
Product: ns-3
Classification: Unclassified
Component: internet
ns-3-dev
All All
: P5 trivial
Assigned To: George Riley
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-05-16 13:43 UTC by John Abraham
Modified: 2011-08-09 19:15 UTC (History)
1 user (show)

See Also:


Attachments
patch (1.20 KB, patch)
2011-05-16 13:50 UTC, John Abraham
Details | Diff
another set (523 bytes, patch)
2011-05-16 18:23 UTC, John Abraham
Details | Diff
consolidated 1 (5.66 KB, patch)
2011-05-16 18:56 UTC, John Abraham
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Abraham 2011-05-16 13:43:08 UTC
seen on optimized builds with g++ 4.6.0

[ 817/1561] cxx: src/internet/helper/internet-stack-helper.cc -> build/optimized/src/internet/helper/internet-stack-helper_1.o                                                                                    
../src/internet/helper/internet-stack-helper.cc: In member function ‘virtual void ns3::InternetStackHelper::EnablePcapIpv4Internal(std::string, ns3::Ptr<ns3::Ipv4>, uint32_t, bool)’:
../src/internet/helper/internet-stack-helper.cc:488:12: error: variable ‘result’ set but not used [-Werror=unused-but-set-variable]
../src/internet/helper/internet-stack-helper.cc: In member function ‘virtual void ns3::InternetStackHelper::EnablePcapIpv6Internal(std::string, ns3::Ptr<ns3::Ipv6>, uint32_t, bool)’:
../src/internet/helper/internet-stack-helper.cc:580:12: error: variable ‘result’ set but not used [-Werror=unused-but-set-variable]
cc1plus: all warnings being treated as errors
Comment 1 John Abraham 2011-05-16 13:50:31 UTC
Created attachment 1127 [details]
patch
Comment 2 John Abraham 2011-05-16 18:23:58 UTC
Created attachment 1136 [details]
another set
Comment 3 John Abraham 2011-05-16 18:56:51 UTC
Created attachment 1138 [details]
consolidated 1