Linux Test Project
 help / color / mirror / Atom feed
From: linuxtestproject.agent@gmail.com
To: Darren Chang <chihsheng@google.com>
Cc: ltp@lists.linux.it, LTP AI Reviewer <ltp-ai@noreply.github.com>
Subject: Re: [LTP] syscalls/mmap09: Drop hardcoded /tmp path
Date: Sun, 26 Apr 2026 05:42:14 +0000	[thread overview]
Message-ID: <20260426054214.3882-1-linuxtestproject.agent@gmail.com> (raw)
In-Reply-To: <20260426035823.3634607-1-chihsheng@google.com>

Hi Darren,

On Sun, 26 Apr 2026, Darren Chang wrote:
> syscalls/mmap09: Drop hardcoded /tmp path

> -       fd = SAFE_OPEN("/tmp/mmaptest", O_RDWR | O_CREAT, 0666);
> +       fd = SAFE_OPEN("mmaptest", O_RDWR | O_CREAT, 0666);

Correct fix — .needs_tmpdir = 1 already chdirs into the temp directory,
so the relative path is the right approach.

Reviewed-by: LTP AI Reviewer <ltp-ai@noreply.github.com>

Pre-existing issues noticed in the surrounding code (not introduced
by this patch):

- mmap09.c:57 — cleanup() guards SAFE_CLOSE with `if (fd)`, but fd is a
  static int that defaults to 0 (stdin). Use `if (fd >= 0)` with fd
  initialized to -1.

---
Note:

Our agent completed the review of the patch.

The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.

Regards,
LTP AI Reviewer

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2026-04-26  5:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-26  3:58 [LTP] [PATCH] syscalls/mmap09: Drop hardcoded /tmp path Darren Chang via ltp
2026-04-26  5:42 ` linuxtestproject.agent [this message]
2026-04-27  2:41 ` Li Wang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260426054214.3882-1-linuxtestproject.agent@gmail.com \
    --to=linuxtestproject.agent@gmail.com \
    --cc=chihsheng@google.com \
    --cc=ltp-ai@noreply.github.com \
    --cc=ltp@lists.linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox