[
https://issues.apache.org/jira/browse/PROTON-546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14020381#comment-14020381
]
Chuck Rolke commented on PROTON-546:
------------------------------------
I confused PROTON-546 and PROTON-596 in a commit message. This commit is for
PROTON-546.
Commit 1601010 from [email protected] in branch 'proton/trunk'
[ https://svn.apache.org/r1601010 ]
PROTON-596: Suppress MSVC warnings
This suppression covers:
>..\..\proton-c\src\object\object.c(232):
warning C4244: 'argument' : conversion from 'ssize_t' to 'int',
possible loss of data
2>..\..\proton-c\src\object\object.c(260):
warning C4267: 'argument' : conversion from 'size_t' to 'int',
possible loss of data
2>..\..\proton-c\src\windows\driver.c(777):
warning C4800: 'int' : forcing value to bool 'true' or 'false'
(performance warning)
6>..\..\..\..\..\tests\tools\apps\c\msgr-recv.c(90):
warning C4996: 'sscanf': This function or variable may be unsafe.
Consider using sscanf_s instead.
To disable deprecation, use _CRT_SECURE_NO_WARNINGS
This covers the majority of the warnings. A typical 64-bit compile has 172
warnings making real problems harder to see. It also follows the
pattern used in Qpid proper.
* C4244 and C4267 could still be real problems.
Try enabling -Wconversion in GCC if you want to be pedantic in Qpid or
Proton.
* C4800 is probably not a risk as it's a fairly idiomatic pattern in C.
* C4996 is MSVC complaining of functions that consume buffers using
{pointer} and not {pointer, size}. They have been the source of seg
faults and innumerable security vulnerabilities throughout the years.
> C++ Windows warnings: conversions and possible loss of data
> -----------------------------------------------------------
>
> Key: PROTON-546
> URL: https://issues.apache.org/jira/browse/PROTON-546
> Project: Qpid Proton
> Issue Type: Bug
> Components: proton-c
> Affects Versions: 0.6
> Reporter: Chuck Rolke
> Assignee: Andrew Stitcher
> Attachments: PROTON-546-size-warnings.txt
>
>
> Windows has other warnings similar to PROTON-545, especially during 64-bit
> builds.
> See attached file for details.
--
This message was sent by Atlassian JIRA
(v6.2#6252)