Re: BUG #18735: Specific multibyte character in psql file path command parameter for Windows

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Koichi Suzuki <koichi(dot)dbms(at)gmail(dot)com>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #18735: Specific multibyte character in psql file path command parameter for Windows
Date: 2024-12-06 05:05:00
Message-ID: 2744315.1733461500@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Koichi Suzuki <koichi(dot)dbms(at)gmail(dot)com> writes:
> Lexical analysis of backshash commands in psql is handled
> by psqlscanslash.l and this module scans iput byte-by-byte, not
> character-by-character. I'm afraid that the cause of the bug is in
> this part.. Is there any way to make this flex syntax local-dependent?

I think you're mistaken: see the "safe_encoding" hackery in
psqlscan.l (which does also operate for the rules in psqlscanslash.l).
Now it could be that psqlscan.l has been misinformed about the
encoding that's in use, but that wouldn't be its fault.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tatsuo Ishii 2024-12-06 05:21:30 Re: BUG #18735: Specific multibyte character in psql file path command parameter for Windows
Previous Message Koichi Suzuki 2024-12-06 04:12:50 Re: BUG #18735: Specific multibyte character in psql file path command parameter for Windows