Skip to content

memory leak #103

Closed
Closed

Description

@jsho000

In the following code:

      int read_bytes = util::read_atmost_n(
                                  fdopen(err_rd_pipe, "r"),
                                  err_buf,
                                  SP_MAX_ERR_BUF_SIZ);
      close(err_rd_pipe);

The value returned by fdopen() is not closed. This causes memory leak.
If you call fclose(), it will close err_rd_pipe. So close(err_rd_pipe) is not necessary.

Activity

  1. arun11299 commented on Jul 5, 2024

    @arun11299
    Owner

    @jsho000 Thank you for reporting. Can you provide a PR after testing the required changes ?

  2. arun11299 commented on Jul 9, 2024

    @arun11299
    Owner

    Will be fixed with #104

  3. added a commit that references this issue on Mar 22, 2025
  4. added a commit that references this issue on Mar 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions