[
https://issues.apache.org/jira/browse/AXIS2C-1533?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Robert Lazarski resolved AXIS2C-1533.
-------------------------------------
Fix Version/s: 2.0.0
Resolution: Fixed
Fixed -Wundef warnings in axutil_log.h:
- __STDC_VERSION → defined(__STDC_VERSION__) && __STDC_VERSION__ (also fixed
typo - was missing trailing underscore)
- WIN32 → defined(WIN32)
Removed redundant redeclarations from 4 headers:
- axutil_stream.h: axutil_stream_free, axutil_stream_free_void_arg
- axis2_transport_in_desc.h: axis2_transport_in_desc_free_void_arg
- axis2_transport_out_desc.h: axis2_transport_out_desc_free_void_arg
- axis2_op.h: axis2_op_free_void_arg
Result: 5 files changed, 2 insertions, 57 deletions - headers now compile
cleanly with
strict warning flags.
> Redundant redeclarations and undefined macros
> ---------------------------------------------
>
> Key: AXIS2C-1533
> URL: https://issues.apache.org/jira/browse/AXIS2C-1533
> Project: Axis2-C
> Issue Type: Bug
> Affects Versions: 1.6.0
> Environment: Fedora 14 x86_64
> gcc (GCC) 4.5.1
> Reporter: Alan Bleasby
> Priority: Minor
> Fix For: 2.0.0
>
>
> In managing our own software project we use the following gcc (4.5.1)
> compiler warning flags.
> -Wall -fno-strict-aliasing -Wextra -Wstrict-prototypes -Wmissing-prototypes
> -Wold-style-definition -Wmissing-declarations -Wwrite-strings -Wshadow
> -Wdeclaration-after-statement -Wundef -Wpointer-arith -Wcast-qual
> -Wcast-align -Wbad-function-cast -Wsign-compare -Wmissing-field-initializers
> -Wmissing-noreturn -Wnested-externs -Wredundant-decls
> With axis2c 1.6.0 this results in the following warnings when compiling
> against the axis2c header files:
> /usr/local/axis2c/include/axis2-1.6.0/axutil_log.h:228:20: warning:
> "__STDC_VERSION" is not defined
> /usr/local/axis2c/include/axis2-1.6.0/axutil_log.h:230:8: warning: "WIN32" is
> not defined
> /usr/local/axis2c/include/axis2-1.6.0/axutil_stream.h:225:5: warning:
> redundant redeclaration of 'axutil_stream_free'
> /usr/local/axis2c/include/axis2-1.6.0/axutil_stream.h:140:5: note: previous
> declaration of 'axutil_stream_free' was here
> /usr/local/axis2c/include/axis2-1.6.0/axutil_stream.h:236:5: warning:
> redundant redeclaration of 'axutil_stream_free_void_arg'
> /usr/local/axis2c/include/axis2-1.6.0/axutil_stream.h:145:5: note: previous
> declaration of 'axutil_stream_free_void_arg' was here
> /usr/local/axis2c/include/axis2-1.6.0/platforms/unix/axutil_unix.h:125:12:
> warning: redundant redeclaration of 'usleep'
> /usr/include/unistd.h:457:12: note: previous declaration of 'usleep' was here
> /usr/local/axis2c/include/axis2-1.6.0/axis2_transport_in_desc.h:320:5:
> warning: redundant redeclaration of 'axis2_transport_in_desc_free_void_arg'
> /usr/local/axis2c/include/axis2-1.6.0/axis2_transport_in_desc.h:82:5: note:
> previous declaration of 'axis2_transport_in_desc_free_void_arg' was here
> /usr/local/axis2c/include/axis2-1.6.0/axis2_transport_out_desc.h:318:5:
> warning: redundant redeclaration of 'axis2_transport_out_desc_free_void_arg'
> /usr/local/axis2c/include/axis2-1.6.0/axis2_transport_out_desc.h:80:5: note:
> previous declaration of 'axis2_transport_out_desc_free_void_arg' was here
> /usr/local/axis2c/include/axis2-1.6.0/axis2_op.h:694:5: warning: redundant
> redeclaration of 'axis2_op_free_void_arg'
> /usr/local/axis2c/include/axis2-1.6.0/axis2_op.h:102:5: note: previous
> declaration of 'axis2_op_free_void_arg' was here
> The first are candidates for using "'defined(X)" rather than just "X". The
> rest, with the exception of the strange usleep
> definition, are indeed multiple redefinitions of the same functions and it
> appears that one definition of could just be
> removed.
> As such warnings make it difficult to see any warnings generated from our own
> code I'd be grateful if they could
> be addressed. Thanks.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]