Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5ad0e89

Browse files
author
Michael Meskes
committed
In ecpglib restore LC_NUMERIC in case of an error.
1 parent6952071 commit5ad0e89

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

‎src/interfaces/ecpg/ecpglib/execute.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1772,8 +1772,12 @@ ECPGdo(const int lineno, const int compat, const int force_indicator, const char
17721772
*/
17731773
if (statement_type==ECPGst_prepnormal)
17741774
{
1775-
if (!ecpg_auto_prepare(lineno,connection_name,compat,&prepname,query))
1775+
if (!ecpg_auto_prepare(lineno,connection_name,compat,&prepname,query)) {
1776+
setlocale(LC_NUMERIC,oldlocale);
1777+
ecpg_free(oldlocale);
1778+
va_end(args);
17761779
return (false);
1780+
}
17771781

17781782
/*
17791783
* statement is now prepared, so instead of the query we have to
@@ -1800,6 +1804,9 @@ ECPGdo(const int lineno, const int compat, const int force_indicator, const char
18001804
else
18011805
{
18021806
ecpg_raise(lineno,ECPG_INVALID_STMT,ECPG_SQLSTATE_INVALID_SQL_STATEMENT_NAME,stmt->command);
1807+
setlocale(LC_NUMERIC,oldlocale);
1808+
ecpg_free(oldlocale);
1809+
va_end(args);
18031810
return (false);
18041811
}
18051812
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp