Uploaded image for project: 'C++ Standard Library'
  1. C++ Standard Library
  2. STDCXX-726 [HP aCC 6.16] many cadvise warnings
  3. STDCXX-729

[HP aCC 6.15] warning #20200-D: potential null pointer dereference in _money_put.cc

    XMLWordPrintableJSON

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 4.2.0
    • Fix Version/s: 4.2.1
    • Component/s: Build and Installation
    • Labels:
      None
    • Environment:

      $ uname -sr && aCC -V
      HP-UX B.11.31
      aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]

      Description

      The compiler (both aCC 6.15 and 6.16) complains about a null pointer dereference in money_put:

      aCC -c  -D_RWSTDDEBUG   -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include  -AA  -g +d  +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    $(TOPDIR)/src/ti_money_put.cpp
      "$(TOPDIR)/include/loc/_money_put.cc", line 130: remark #4296-D: arithmetic operation on boolean type
                - !__dint - !!__fd - (__dint > 0 ? __dint : -__dint) - __fd
                  ^
                detected during instantiation of "_OutputIter std::money_put<_CharT, _OutputIter>::_C_put(_OutputIter, int, std::ios_base &, _CharT, const _CharT *, unsigned long, int, const char *, unsigned long) const [with _CharT=char, _OutputIter=std::ostreambuf_iterator<char, std::char_traits<char>>]" at line 322
      
      "$(TOPDIR)/include/loc/_money_put.cc", line 130: remark #4296-D: arithmetic operation on boolean type
                - !__dint - !!__fd - (__dint > 0 ? __dint : -__dint) - __fd
                            ^
                detected during instantiation of "_OutputIter std::money_put<_CharT, _OutputIter>::_C_put(_OutputIter, int, std::ios_base &, _CharT, const _CharT *, unsigned long, int, const char *, unsigned long) const [with _CharT=char, _OutputIter=std::ostreambuf_iterator<char, std::char_traits<char>>]" at line 322
      
      "$(TOPDIR)/include/loc/_money_put.cc", line 131: remark #4296-D: arithmetic operation on boolean type
                - (   money_base::space == __fmat.field [1]
                  ^
                detected during instantiation of "_OutputIter std::money_put<_CharT, _OutputIter>::_C_put(_OutputIter, int, std::ios_base &, _CharT, const _CharT *, unsigned long, int, const char *, unsigned long) const [with _CharT=char, _OutputIter=std::ostreambuf_iterator<char, std::char_traits<char>>]" at line 322
      
      "$(TOPDIR)/include/loc/_money_put.cc", line 94, procedure _C_put: warning #20200-D: Potential null pointer dereference through __pun0 is detected (null definition:$(TOPDIR)/include/loc/_money_put.cc, line 74)
      
      "$(TOPDIR)/include/loc/_money_put.cc", line 90, procedure _C_put: warning #20200-D: Potential null pointer dereference through __pun1 is detected (null definition:$(TOPDIR)/include/loc/_money_put.cc, line 79)
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                sebor Martin Sebor
                Reporter:
                sebor Martin Sebor
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - 1h Original Estimate - 1h
                  1h
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 2h
                  2h