You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@stdcxx.apache.org by "Scott (Yu) Zhong (JIRA)" <ji...@apache.org> on 2008/03/13 22:04:24 UTC
[jira] Created: (STDCXX-755) Potential null pointer dereference in
locale.cpp
Potential null pointer dereference in locale.cpp
------------------------------------------------
Key: STDCXX-755
URL: https://issues.apache.org/jira/browse/STDCXX-755
Project: C++ Standard Library
Issue Type: Sub-task
Components: Test Driver
Affects Versions: 4.2.0
Environment: $ uname -sr && aCC -V
HP-UX B.11.31
aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
Reporter: Scott (Yu) Zhong
Fix For: 4.2.1
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Travis Vitek resolved STDCXX-755.
---------------------------------
Resolution: Fixed
Committed to trunk in [r644821|http://svn.apache.org/viewvc?view=rev&revision=644821].
Will close when merged to 4.2.1 and verified.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Time Spent: 2h
> Remaining Estimate: 0h
>
> When compiled with HP aCC 6.16 with the {{+w}} option, the [locale.cpp|http://svn.apache.org/repos/asf/stdcxx/trunk/tests/src/locale.cpp] test driver source file produces a bunch of warnings (and remarks):
> {noformat}
> aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include \
> -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 \
> +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 \
> +W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 \
> $(TOPDIR)/tests/src/locale.cpp
> "$(TOPDIR)/include/limits", line 449: warning #4070-D: floating point underflow exception
> _RWSTD_STATIC_FUN (long double, (min), _RWSTD_LDBL_MIN)
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 1534: remark #4298-D: addition result could be truncated before cast to bigger sized type
> offset += (len + 1);
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 380, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 375)
> "$(TOPDIR)/tests/src/locale.cpp", line 472, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 469)
> "$(TOPDIR)/tests/src/locale.cpp", line 1215, procedure _rw_all_locales: warning #20206-D: Out of bound access (In expression "strcpy((char*)entry->locale_name, (char*)locale)", entry->locale_name (type: char [64]) has byte range [0 .. 63], writing byte range [0 .. 127].)
> {noformat}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Scott (Yu) Zhong (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Scott (Yu) Zhong updated STDCXX-755:
------------------------------------
Summary: [HP aCC 6.16] Potential null pointer dereference in locale.cpp (was: [HP aCC 6.15] Potential null pointer dereference in locale.cpp)
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Martin Sebor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12585221#action_12585221 ]
Martin Sebor commented on STDCXX-755:
-------------------------------------
Hmm. I see a bunch or remarks and a couple of instances of warning #2177 but no #20200. I already silenced the remark #4300 from <iomanip> in [r643078|http://svn.apache.org/viewvc?view=rev&revision=643078]. Remark #4298 from _localedef.h is annoying and causes a lot of noise in many compilations (by my count there were 95 instances of it as of last Friday) but I haven't been able to bring myself to uglify the code enough to silence it yet...
{noformat}
aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 $(TOPDIR)/util/locale.cpp
"$(TOPDIR)/include/iomanip", line 90: remark #4300-D: Overflow while computing constant in left shift operation
& ~(_RWSTD_IOS_BASEMASK << _RWSTD_IOS_BASEOFF)
^
"$(TOPDIR)/util/locale.cpp", line 244: remark #4271-D: type conversion may lose sign
loc_path = std::string (env_val, slash - env_val);
^
"$(TOPDIR)/include/loc/_localedef.h", line 160: remark #4298-D: addition result could be truncated before cast to bigger sized type
return (wtolower_off - wtoupper_off) / sizeof (__rw_upper_elm);
^
"$(TOPDIR)/include/loc/_localedef.h", line 164: remark #4298-D: addition result could be truncated before cast to bigger sized type
return (wmask_off - wtolower_off) / sizeof (__rw_lower_elm);
^
"$(TOPDIR)/include/loc/_localedef.h", line 168: remark #4298-D: addition result could be truncated before cast to bigger sized type
return charmap_off - codeset_off;
^
"$(TOPDIR)/include/loc/_localedef.h", line 172: remark #4298-D: addition result could be truncated before cast to bigger sized type
return wtoupper_off - charmap_off;
^
"$(TOPDIR)/include/loc/_localedef.h", line 122: remark #4299-D: multiply result could be truncated before cast to bigger sized type
return *(_RWSTD_ARRAY_ELM (wchar_t, wchar_off, off * 2));
^
"$(TOPDIR)/include/loc/_localedef.h", line 128: remark #4298-D: addition result could be truncated before cast to bigger sized type
return *(_RWSTD_ARRAY_ELM (wchar_t, wchar_off, off * 2 + 1));
^
"$(TOPDIR)/util/locale.cpp", line 1419: remark #4298-D: addition result could be truncated before cast to bigger sized type
i < num_punct_st->punct_ext_off - num_punct_st->grouping_off - 2;
^
"$(TOPDIR)/util/locale.cpp", line 1580: remark #4298-D: addition result could be truncated before cast to bigger sized type
i < mon_punct_st->punct_ext_off - mon_punct_st->grouping_off - 2;
^
"$(TOPDIR)/util/locale.cpp", line 788: warning #2177-D: function "print_c_lc_collate" was declared but never referenced
print_c_lc_collate ()
^
"$(TOPDIR)/util/locale.cpp", line 796: warning #2177-D: function "get_wchar_from_offset" was declared but never referenced
get_wchar_from_offset(unsigned int offset,
^
{noformat}
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Travis Vitek reassigned STDCXX-755:
-----------------------------------
Assignee: Travis Vitek
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12585190#action_12585190 ]
Travis Vitek commented on STDCXX-755:
-------------------------------------
There are many more warnings than just these two.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12585231#action_12585231 ]
Travis Vitek commented on STDCXX-755:
-------------------------------------
That is because you're looking at the output for the wrong file, probably because Scott made a cutty-paste error when he pasted the command line. The file that the warnings are generated for is {{tests/src/locale.cpp}}.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (STDCXX-755) [HP aCC 6.15] Potential null pointer
dereference in locale.cpp
Posted by "Scott (Yu) Zhong (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Scott (Yu) Zhong updated STDCXX-755:
------------------------------------
Summary: [HP aCC 6.15] Potential null pointer dereference in locale.cpp (was: Potential null pointer dereference in locale.cpp)
> [HP aCC 6.15] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12585232#action_12585232 ]
Travis Vitek commented on STDCXX-755:
-------------------------------------
Of course, when testing, I'm compiling the code on trunk, not the code on 4.2.x. Since the trunk code will be merged out to 4.2.x, I figured this would be a good thing to do. Obviously that will have some impact on the messages seen.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Scott (Yu) Zhong (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Scott (Yu) Zhong updated STDCXX-755:
------------------------------------
Description:
aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
+W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
til/locale.cpp
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
was:
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
add compile line to description
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
> +W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
> til/locale.cpp
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
> "/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Farid Zaripov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12589959#action_12589959 ]
Farid Zaripov commented on STDCXX-755:
--------------------------------------
Merged in 4.2.x branch thus: http://svn.apache.org/viewvc?view=rev&revision=648752
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Time Spent: 2h
> Remaining Estimate: 0h
>
> When compiled with HP aCC 6.16 with the {{+w}} option, the [locale.cpp|http://svn.apache.org/repos/asf/stdcxx/trunk/tests/src/locale.cpp] test driver source file produces a bunch of warnings (and remarks):
> {noformat}
> aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include \
> -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 \
> +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 \
> +W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 \
> $(TOPDIR)/tests/src/locale.cpp
> "$(TOPDIR)/include/limits", line 449: warning #4070-D: floating point underflow exception
> _RWSTD_STATIC_FUN (long double, (min), _RWSTD_LDBL_MIN)
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 1534: remark #4298-D: addition result could be truncated before cast to bigger sized type
> offset += (len + 1);
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 380, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 375)
> "$(TOPDIR)/tests/src/locale.cpp", line 472, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 469)
> "$(TOPDIR)/tests/src/locale.cpp", line 1215, procedure _rw_all_locales: warning #20206-D: Out of bound access (In expression "strcpy((char*)entry->locale_name, (char*)locale)", entry->locale_name (type: char [64]) has byte range [0 .. 63], writing byte range [0 .. 127].)
> {noformat}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Travis Vitek (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Travis Vitek closed STDCXX-755.
-------------------------------
Closing resolved and verified 4.2.1 issue.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Time Spent: 2h
> Remaining Estimate: 0h
>
> When compiled with HP aCC 6.16 with the {{+w}} option, the [locale.cpp|http://svn.apache.org/repos/asf/stdcxx/trunk/tests/src/locale.cpp] test driver source file produces a bunch of warnings (and remarks):
> {noformat}
> aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include \
> -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 \
> +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 \
> +W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 \
> $(TOPDIR)/tests/src/locale.cpp
> "$(TOPDIR)/include/limits", line 449: warning #4070-D: floating point underflow exception
> _RWSTD_STATIC_FUN (long double, (min), _RWSTD_LDBL_MIN)
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 1534: remark #4298-D: addition result could be truncated before cast to bigger sized type
> offset += (len + 1);
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 380, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 375)
> "$(TOPDIR)/tests/src/locale.cpp", line 472, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 469)
> "$(TOPDIR)/tests/src/locale.cpp", line 1215, procedure _rw_all_locales: warning #20206-D: Out of bound access (In expression "strcpy((char*)entry->locale_name, (char*)locale)", entry->locale_name (type: char [64]) has byte range [0 .. 63], writing byte range [0 .. 127].)
> {noformat}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (STDCXX-755) [HP aCC 6.16] Potential null pointer
dereference in locale.cpp
Posted by "Martin Sebor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-755?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Sebor updated STDCXX-755:
--------------------------------
Description:
When compiled with HP aCC 6.16 with the {{+w}} option, the [locale.cpp|http://svn.apache.org/repos/asf/stdcxx/trunk/tests/src/locale.cpp] test driver source file produces a bunch of warnings (and remarks):
{noformat}
aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include \
-AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 \
+W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 \
+W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 \
$(TOPDIR)/tests/src/locale.cpp
"$(TOPDIR)/include/limits", line 449: warning #4070-D: floating point underflow exception
_RWSTD_STATIC_FUN (long double, (min), _RWSTD_LDBL_MIN)
^
"$(TOPDIR)/tests/src/locale.cpp", line 1534: remark #4298-D: addition result could be truncated before cast to bigger sized type
offset += (len + 1);
^
"$(TOPDIR)/tests/src/locale.cpp", line 380, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 375)
"$(TOPDIR)/tests/src/locale.cpp", line 472, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 469)
"$(TOPDIR)/tests/src/locale.cpp", line 1215, procedure _rw_all_locales: warning #20206-D: Out of bound access (In expression "strcpy((char*)entry->locale_name, (char*)locale)", entry->locale_name (type: char [64]) has byte range [0 .. 63], writing byte range [0 .. 127].)
{noformat}
was:
aCC -c -mt -I/amd/devco/scottz/stdcxx/4.2.x/include -I/build/scottz/12d/include -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193
+W2236 +W2261 +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 +W4272 +W4284 +W4285 +W4286 /amd/devco/scottz/stdcxx/4.2.x/u
til/locale.cpp
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 369, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 364)
"/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp", line 461, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:/amd/devco/scottz/stdcxx/4.2.x/tests/src/locale.cpp, line 458)
Corrected compiler output in Description.
> [HP aCC 6.16] Potential null pointer dereference in locale.cpp
> --------------------------------------------------------------
>
> Key: STDCXX-755
> URL: https://issues.apache.org/jira/browse/STDCXX-755
> Project: C++ Standard Library
> Issue Type: Sub-task
> Components: Test Driver
> Affects Versions: 4.2.0
> Environment: $ uname -sr && aCC -V
> HP-UX B.11.31
> aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]
> Reporter: Scott (Yu) Zhong
> Assignee: Travis Vitek
> Fix For: 4.2.1
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> When compiled with HP aCC 6.16 with the {{+w}} option, the [locale.cpp|http://svn.apache.org/repos/asf/stdcxx/trunk/tests/src/locale.cpp] test driver source file produces a bunch of warnings (and remarks):
> {noformat}
> aCC -c -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include \
> -AA +O2 +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 +W2193 +W2236 +W2261 \
> +W2340 +W2401 +W2487 +W4227 +W4229 +W4231 +W4235 +W4237 +W4249 +W4255 \
> +W4272 +W4284 +W4285 +W4286 +W4296 +W4297 +W3348 \
> $(TOPDIR)/tests/src/locale.cpp
> "$(TOPDIR)/include/limits", line 449: warning #4070-D: floating point underflow exception
> _RWSTD_STATIC_FUN (long double, (min), _RWSTD_LDBL_MIN)
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 1534: remark #4298-D: addition result could be truncated before cast to bigger sized type
> offset += (len + 1);
> ^
> "$(TOPDIR)/tests/src/locale.cpp", line 380, procedure rw_locales: warning #20200-D: Potential null pointer dereference through slocname is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 375)
> "$(TOPDIR)/tests/src/locale.cpp", line 472, procedure rw_locales: warning #20200-D: Potential null pointer dereference through return of call to malloc is detected (null definition:$(TOPDIR)/tests/src/locale.cpp, line 469)
> "$(TOPDIR)/tests/src/locale.cpp", line 1215, procedure _rw_all_locales: warning #20206-D: Out of bound access (In expression "strcpy((char*)entry->locale_name, (char*)locale)", entry->locale_name (type: char [64]) has byte range [0 .. 63], writing byte range [0 .. 127].)
> {noformat}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.