patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Ophir Munk <ophirmu@nvidia.com>
Cc: Ori Kam <orika@nvidia.com>, "dev@dpdk.org" <dev@dpdk.org>,
	Raslan Darawsheh <rasland@nvidia.com>,
	stable@dpdk.org,
	Lukasz Wojciechowski <l.wojciechow@partner.samsung.com>
Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH v1] app/regex: fix segfault in getopt_long call
Date: Tue, 20 Oct 2020 00:06:39 +0200
Message-ID: <1925730.gUPrjPanqK@thomas> (raw)
In-Reply-To: <ae33c2bc-3d69-0d66-2a92-ea7a766926d5@partner.samsung.com>

> >> getopt_long() parses command-line arguments. One of its arguments
> >> 'longopts' is a pointer to the first element of an array of struct
> >> option.  The last element of the array has to be filled with zeros
> >> to mark the end of options. For example:
> >>
> >> struct option longopts[] = {
> >> { "help",  0, 0, ARG_HELP},
> >> ....
> >> /* End of options */
> >> { 0, 0, 0, 0 }
> >> };
> >>
> >> This commit adds the last element. Prior to this commit getopt_long()
> >> continued parsing beyond the longopts[] array which occasionally caused
> >> segmentation faults.
> >>
> >> Fixes: de06137cb295 ("app/regex: add RegEx test application")
> >> Cc: stable@dpdk.org
> >>
> >> Signed-off-by: Ophir Munk <ophirmu@nvidia.com>
> > Acked-by: Ori Kam <orika@nvidia.com>
> Acked-by: Lukasz Wojciechowski <l.wojciechow@partner.samsung.com>

Applied, thanks




      parent reply	other threads:[~2020-10-19 22:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-18 14:21 [dpdk-stable] " Ophir Munk
2020-10-19  7:46 ` Ori Kam
2020-10-19  8:13   ` [dpdk-stable] [dpdk-dev] " Lukasz Wojciechowski
2020-10-19  8:39     ` Ophir Munk
2020-10-19 22:05       ` Thomas Monjalon
2020-10-19 22:06     ` Thomas Monjalon [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=1925730.gUPrjPanqK@thomas \
    --to=thomas@monjalon.net \
    --cc=dev@dpdk.org \
    --cc=l.wojciechow@partner.samsung.com \
    --cc=ophirmu@nvidia.com \
    --cc=orika@nvidia.com \
    --cc=rasland@nvidia.com \
    --cc=stable@dpdk.org \
    /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

patches for DPDK stable branches

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ https://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git