public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: Matt Rice <ratmice@gmail.com>
To: systemtap@sourceware.org
Subject: Ignore -xflags not separated by a space
Date: Tue, 30 Jan 2024 00:16:44 +0000	[thread overview]
Message-ID: <CACTLOFqVgB=3p-b8x51uaph4buopTTvHG26s-dHPxP7qMrMXCw@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 285 bytes --]

The ignore_options2 currently ignores flags like '-x flags', skipping
the next argument,
but it lets cases like '-xflags'  fall through.

This can be seen in a couple of places primarily with -xnolibs:
https://github.com/joyent/libuv/issues/1478
https://github.com/agentzh/usdt-sample

[-- Attachment #2: 0001-ignore-for-xflags-not-separated-by-a-space.patch --]
[-- Type: text/x-patch, Size: 845 bytes --]

From 1b13d0263df84a98b0d7ac4e5c4d111136addd83 Mon Sep 17 00:00:00 2001
From: matt rice <ratmice@gmail.com>
Date: Mon, 29 Jan 2024 16:02:44 -0800
Subject: [PATCH] ignore for -xflags not separated by a space.

Signed-off-by: matt rice <ratmice@gmail.com>
---
 dtrace.in | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/dtrace.in b/dtrace.in
index 73a6f22e2..1a762c7a5 100644
--- a/dtrace.in
+++ b/dtrace.in
@@ -369,6 +369,8 @@ def main():
         elif sys.argv[i] in ignore_options2:
             i += 1
             pass                # dtrace users sometimes pass these flags
+        elif sys.argv[i].startswith(tuple(ignore_options2)):
+            pass                # dtrace users sometimes pass flags like '-xnolibs'
         elif sys.argv[i] == "--help":
             dtrace_help()
         elif sys.argv[i][0] == "-":
-- 
2.43.0


                 reply	other threads:[~2024-01-30  0:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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='CACTLOFqVgB=3p-b8x51uaph4buopTTvHG26s-dHPxP7qMrMXCw@mail.gmail.com' \
    --to=ratmice@gmail.com \
    --cc=systemtap@sourceware.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
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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).