Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4071525

(porting) malloc/free used instead of sysMalloc/sysFree

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • 1.2.0
    • hotspot
    • None
    • generic
    • generic

      There are numerous places that malloc/free have crept back into the
      main share runtime code. We did a good job of chaning these in JDK1.1.
      These need to be replaced since some licenses do not use malloc/free
      but the cover routines.

      There are also places that we use strdup, which calls malloc and can
      cause memory leaks.

      use the following find command:


       find . -name SCCS -prune -o -name '*.[ch]' -exec grep " .alloc(" /dev/null {} \;

       find . -name SCCS -prune -o -name '*.[ch]' -exec grep " free(" /dev/null {} \;

            never Tom Rodriguez
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: