Re: [PATCH] Patch to fix a crash of psql

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
Cc: Tatsuo Ishii *EXTERN* <ishii(at)postgresql(dot)org>, jianggq(at)cn(dot)fujitsu(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH] Patch to fix a crash of psql
Date: 2012-11-30 13:10:26
Message-ID: 50B8B042.7020301@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 11/30/12 3:26 AM, Albe Laurenz wrote:
> Tatsuo Ishii wrote:
>> postgres=# \i ~/sql
>> CREATE DATABASE
>> You are now connected to database "mydb" as user "t-ishii".
>> CREATE SCHEMA
>> psql:/home/t-ishii/sql:7: warning: possible conflict between client
> encoding SJIS and input file
>> encoding
>> CREATE TABLE
>>
>> Comments?
>
> I wonder about the "possible".
>
> Could there be false positives with the test?
> If yes, I don't like the idea.
> If there is no possibility for false positives, I'd say
> that the "possible" should go. Maybe it should even be
> an error and no warning then.

Yes, encoding mismatches are generally an error.

I think the message should be more precise. Nobody will know what an
"encoding conflict" is. The error condition is "last multibyte
character ran over end of file" or something like that, which should be
clearer.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavan Deolasee 2012-11-30 13:13:37 Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?
Previous Message Pavan Deolasee 2012-11-30 13:05:05 Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?