mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-05 04:30:38 +03:00
Fix the CLI so that it does not terminate input when an Oracle or MS-SQL
command terminator mark is seen in the middle of a string literal. Ticket #3490. (CVS 5878) FossilOrigin-Name: 68662e3b487b80b2c94cd2376060388bd8df0e4e
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
** This file contains code to implement the "sqlite" command line
|
||||
** utility for accessing SQLite databases.
|
||||
**
|
||||
** $Id: shell.c,v 1.185 2008/08/11 19:12:35 drh Exp $
|
||||
** $Id: shell.c,v 1.186 2008/11/11 00:30:12 drh Exp $
|
||||
*/
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
@@ -1699,7 +1699,7 @@ static int process_input(struct callback_data *p, FILE *in){
|
||||
}
|
||||
continue;
|
||||
}
|
||||
if( _is_command_terminator(zLine) ){
|
||||
if( _is_command_terminator(zLine) && sqlite3_complete(zSql) ){
|
||||
memcpy(zLine,";",2);
|
||||
}
|
||||
nSqlPrior = nSql;
|
||||
|
||||
Reference in New Issue
Block a user