• Mayank Prasad's avatar
    Bug#11764633 : 57491: THD->MAIN_DA.IS_OK() ASSERT IN EMBEDDED · 55d3381c
    Mayank Prasad authored
    Issue:
    While running embedded server, if client issues TEE command (\T foo/bar) and
    "foo/bar" directory doesn't exist, it is suppose to give error. But it was
    aborting.  This was happening because wrong error handler was being called.
    
    Solution:
    Modified calls to correct error handler. In embedded server case, there are 
    two error handler (client and server) which are supposed to be called based 
    on which context code is in. If it is in client context, client error handler
    should be called otherwise server.
    
    Test case:
    Test case automation is not possible as current (following) code doesn't 
    allow '\T' to be executed from command line (OR command read from a file):
    [client/mysql.cc]
    ...
     static int
     com_tee(String *buffer __attribute__((unused)),
             char *line __attribute__((unused)))
     {
       char file_name[FN_REFLEN], *end, *param;
    
       if (status.batch) << THIS IS TRUE WHILE EXECUTING FROM COMMAND LINE.
          return 0;
     ...
    So, not adding test case in GA. WIll add a test case in mysql-trunk after 
    removing above code so that this could be properly tested before GA.
    55d3381c
sql_class.h 99.6 KB