From: | "Karl O(dot) Pinc" <kop(at)meme(dot)com> |
---|---|
To: | Gilles Darold <gilles(dot)darold(at)dalibo(dot)com> |
Cc: | Christoph Berg <myon(at)debian(dot)org>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Shulgin, Oleksandr" <oleksandr(dot)shulgin(at)zalando(dot)de>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, kop(at)meme(dot)com |
Subject: | Re: Patch to implement pg_current_logfile() function |
Date: | 2016-11-23 13:47:00 |
Message-ID: | 20161123074700.333f9089@slate.meme.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, 23 Nov 2016 03:21:05 -0600
"Karl O. Pinc" <kop(at)meme(dot)com> wrote:
> But also, you can't use strtok() to parse lbuffer because
> the path you're returning can contain a space.
Maybe on the 2nd call to strtok() you could pass ""
as the 2nd argument? That'd be a little wonky but
the man page does not say you can't have an empty
set of delimiters. On the other hand strtok() is
not a perfect choice, you don't want to "collapse"
adjacent delimiters in the parsed string or ignore
leading spaces. I'd prefer a strstr() solution.
Or strchr() even better.
Regards.
Karl <kop(at)meme(dot)com>
Free Software: "You don't pay back, you pay forward."
-- Robert A. Heinlein
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2016-11-23 13:50:10 | Re: Hash Indexes |
Previous Message | Craig Ringer | 2016-11-23 13:37:38 | Re: Logical decoding on standby |