List:Commits« Previous MessageNext Message »
From:Marc Alff Date:August 25 2008 6:30pm
Subject:Re: bzr commit into mysql-6.0-wl2110-review branch (marc.alff:2675)
WL#2110
View as plain text  
Hi Davi


Davi Arnaut wrote:
> Hi Marc,
>
> Patch looks fine, one comment below.
>
> Marc Alff wrote:
>   
>> #At file:///home/malff/BZR-TREE/mysql-6.0-wl2110-review-part6/
>>
>>  2675 Marc Alff	2008-07-22
>>       WL#2110 (Stored Procedures: Implement SIGNAL)
>>       
>>       Formal review part 6/10: protocol
>>       
>>       This patch implements minor changes in the protocol layer.
>>       In particular, the SQLSTATE of a packet is not implied anymore
>>       by the error number, but provided by the caller.
>> modified:
>>   libmysqld/lib_sql.cc
>>   sql/protocol.cc
>>   sql/protocol.h
>>
>>     
>
> <snip>
>
>   
>>  
>>  void send_warning(THD *thd, uint sql_errno, const char *err=0);
>> -void net_send_error(THD *thd, uint sql_errno=0, const char *err=0);
>> +void net_send_error(THD *thd, uint sql_errno, const char *err,
>> +                    const char* sqlstate);
>>     
>
> Wouldn't it be better to pass the SQL_condition?
>
>   
The error packet message/error code/sql state does not come from the 
SQL_condition,
but from the statement diagnostics area.

In both cases, the protocol code is a very low layer, and should not 
contain references to the higher SQL layer,
to avoid creating a dependency cycle between modules in the server 
implementation.

Regards,
-- Marc


Thread
bzr commit into mysql-6.0-wl2110-review branch (marc.alff:2675) WL#2110Marc Alff23 Jul
  • Re: bzr commit into mysql-6.0-wl2110-review branch (marc.alff:2675)WL#2110Davi Arnaut15 Aug
    • Re: bzr commit into mysql-6.0-wl2110-review branch (marc.alff:2675)WL#2110Marc Alff25 Aug