Linux Test Project
 help / color / mirror / Atom feed
From: Petr Vorel <pvorel@suse.cz>
To: Avinesh Kumar <akumar@suse.de>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH] open04.c: convert to new LTP API
Date: Thu, 1 Sep 2022 22:49:17 +0200	[thread overview]
Message-ID: <YxEazcN3+vkU/lVQ@pevik> (raw)
In-Reply-To: <8989849.CDJkKcVGEf@localhost>

Hi Avinesh,

> > I suggest to merge with these fixes:

> > * added free (if needed - that was in the original source)
> > * fixed cleanup (don't run SAFE_CLOSE() if previous SAFE_OPEN() or SAFE_MALLOC()
> >   failed)
> > * use TST_EXP_FAIL() - the same result as TST_EXP_FAIL2() with shorter code
> TST_EXP_FAIL2() is correct here as you mentioned in previous reply.

> > * allocate memory needed (it's actually -2)
> fds_limit(1024) - first(3) is correct as we need to allocate memory for1021 int fds.
> Test executes fine even with (fds_limit - first - 2) probably because malloc allocating
> more than requested memory.

Yes, thank you for correcting me, I forget the basic (the alignment of
dynamically allocating memory).

> > * #define FNAME "open04"

> > If it's ok, I'll merge it.
> please go ahead and merge with rest of the suggestions, or let me know if I should
> sent v2.

Merged, thanks!

Kind regards,
Petr

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

      reply	other threads:[~2022-09-01 20:49 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-14  6:07 [LTP] [PATCH] open04.c: convert to new LTP API Avinesh Kumar
2022-09-01  6:32 ` Petr Vorel
2022-09-01 11:39   ` Petr Vorel
2022-09-01 16:07   ` Avinesh Kumar
2022-09-01 20:49     ` Petr Vorel [this message]

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=YxEazcN3+vkU/lVQ@pevik \
    --to=pvorel@suse.cz \
    --cc=akumar@suse.de \
    --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