Re: ecpg - GRANT bug - Mailing list pgsql-hackers

From Lee Kindness
Subject Re: ecpg - GRANT bug
Date
Msg-id 15307.64910.421696.852199@elsick.csl.co.uk
Whole thread Raw
In response to Re: ecpg - GRANT bug  (Lee Kindness <lkindness@csl.co.uk>)
Responses Re: ecpg - GRANT bug
Re: ecpg - GRANT bug
Re: ecpg - GRANT bug
Re: ecpg - GRANT bug
Re: ecpg - GRANT bug
List pgsql-hackers
Lee Kindness writes:> Patch below, it changes:>  1. A number of mmerror(ET_ERROR) to mmerror(ET_NOTICE), passing on>
the (currently) unsupported options to the backend with warning.>  2. Standardises warning messages in such cases.>  3.
Correctstypo in passing of 'CREATE FUNCTION/INOUT' parameter.
 

And the patch below corrects a pet peeve I have with ecpg, all errors
and warnings are output with a line number one less than reality...

Lee.

*** ./interfaces/ecpg/preproc/preproc.y.orig    Tue Oct 16 10:19:27 2001
--- ./interfaces/ecpg/preproc/preproc.y    Tue Oct 16 10:19:49 2001
***************
*** 36,49 ****     switch(type)     {     case ET_NOTICE: 
!         fprintf(stderr, "%s:%d: WARNING: %s\n", input_filename, yylineno, error);          break;     case ET_ERROR:
!         fprintf(stderr, "%s:%d: ERROR: %s\n", input_filename, yylineno, error);         ret_value = PARSE_ERROR;
  break;     case ET_FATAL:
 
!         fprintf(stderr, "%s:%d: ERROR: %s\n", input_filename, yylineno, error);         exit(PARSE_ERROR);     } }
--- 36,52 ----     switch(type)     {     case ET_NOTICE: 
!         fprintf(stderr, "%s:%d: WARNING: %s\n", input_filename,
!             yylineno + 1, error);          break;     case ET_ERROR:
!         fprintf(stderr, "%s:%d: ERROR: %s\n", input_filename,
!             yylineno + 1, error);         ret_value = PARSE_ERROR;         break;     case ET_FATAL:
!         fprintf(stderr, "%s:%d: ERROR: %s\n", input_filename,
!             yylineno + 1, error);         exit(PARSE_ERROR);     } }


pgsql-hackers by date:

Previous
From: Tatsuo Ishii
Date:
Subject: Re: pg_client_encoding
Next
From: Tatsuo Ishii
Date:
Subject: delayed mail?