lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140729151253.GR7831@kernel.org>
Date:	Tue, 29 Jul 2014 12:12:53 -0300
From:	Arnaldo Carvalho de Melo <acme@...nel.org>
To:	Minchan Kim <minchan@...nel.org>
Cc:	Namhyung Kim <namhyung@...nel.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Ingo Molnar <mingo@...nel.org>,
	Paul Mackerras <paulus@...ba.org>,
	Namhyung Kim <namhyung.kim@....com>,
	LKML <linux-kernel@...r.kernel.org>,
	Jiri Olsa <jolsa@...hat.com>, David Ahern <dsahern@...il.com>
Subject: Re: [PATCH 1/2] perf tools: Ensure --symfs ends with '/'

Em Tue, Jul 29, 2014 at 10:26:57PM +0900, Minchan Kim escreveu:
> On Tue, Jul 29, 2014 at 09:33:05AM -0300, Arnaldo Carvalho de Melo wrote:
> > Can you please try the patch below instead?
> 
> Tested. It works.
> And I'd like to say that [2/2] in patchset is handy to me.

Ok, here it is, refreshed, will apply with Namhyung as author as the
change should be functionally equivalent to what he did.

Please check that it works as expected,

Thanks,

- Arnaldo

---

diff --git a/tools/perf/util/symbol.c b/tools/perf/util/symbol.c
index c3549d5955ea..223a7ffe0d93 100644
--- a/tools/perf/util/symbol.c
+++ b/tools/perf/util/symbol.c
@@ -1862,13 +1862,21 @@ int symbol__init(void)
 		       symbol_conf.sym_list_str, "symbol") < 0)
 		goto out_free_comm_list;
 
+	if (symbol_conf.symfs[0] != '\0') {
+		symfs = realpath(symbol_conf.symfs, NULL);
+		if (symfs == NULL) {
+			pr_debug("Cannot apply symfs: %s: %s\n",
+				symbol_conf.symfs, strerror(errno));
+			return -1;
+		}
+	} else {
+		symfs = symbol_conf.symfs;
+	}
+
 	/*
 	 * A path to symbols of "/" is identical to ""
 	 * reset here for simplicity.
 	 */
-	symfs = realpath(symbol_conf.symfs, NULL);
-	if (symfs == NULL)
-		symfs = symbol_conf.symfs;
 	if (strcmp(symfs, "/") == 0)
 		symbol_conf.symfs = "";
 	if (symfs != symbol_conf.symfs)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ