Uploaded image for project: 'Axis2-C'
  1. Axis2-C
  2. AXIS2C-1596

Memory leaks in src/core/transport/http/util/http_transport_utils.c

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 1.7.0
    • Component/s: transport/http
    • Labels:

      Description

      There are 3 memory leaks in src/core/transport/http/util/http_transport_utils.c (current SVN trunk):

      1) query_str is allocated via axutil_strdup() at http_transport_utils.c:1488, but never freed. Should be freed in the end of axis2_http_transport_utils_get_request_params()

      5 bytes leaked at 0x6000000001419300 (0.06% of all bytes leaked)
      #0 axutil_allocator_malloc_impl() at allocator.c:99
      #1 axutil_strdup() at string.c:267
      #2 axis2_http_transport_utils_get_request_params() at http_transport_utils.c:1488
      #3 axis2_http_worker_process_request() at http_worker.c:484

      2) A string is allocated by axutil_hash_first() at http_transport_utils.c:1827, but it is not freed.

      96 bytes leaked in 3 blocks (0.37% of all bytes leaked)
      These range in size from 32 to 32 bytes and are allocated
      #0 axutil_allocator_malloc_impl() at allocator.c:99
      #1 axutil_hash_first() at hash.c:159
      #2 axis2_http_transport_utils_get_services_static_wsdl() at http_transport_utils.c:1827
      #3 axis2_http_worker_process_request() at http_worker.c:563

      3) axutil_parse_request_url_for_svc_and_op() allocates and returns three chunks of memory that are never freed when called from axis2_http_transport_utils_get_services_static_wsdl() at http_transport_utils.c:1810

      48 bytes leaked in 3 blocks (0.18% of all bytes leaked)
      These range in size from 16 to 16 bytes and are allocated
      #0 axutil_allocator_malloc_impl() at allocator.c:99
      #1 axutil_parse_request_url_for_svc_and_op() at utils.c:407
      #2 axis2_http_transport_utils_get_services_static_wsdl() at http_transport_utils.c:1810
      #3 axis2_http_worker_process_request() at http_worker.c:563

      48 bytes leaked in 3 blocks (0.18% of all bytes leaked)
      These range in size from 16 to 16 bytes and are allocated
      #0 axutil_allocator_malloc_impl() at allocator.c:99
      #1 axutil_strdup() at string.c:267
      #2 axutil_parse_request_url_for_svc_and_op() at utils.c:454
      #3 axis2_http_transport_utils_get_services_static_wsdl() at http_transport_utils.c:1810

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              ipechorin Ivan Pechorin
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: