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

Commit514a731

Browse files
committed
Simplify static function in extension.c
An extra argument for the filename defining the extension scriptlocation was present, aimed at being used for error reporting, but hasnever been used. This was around since extensions have been added ind9572c4.Author: Yugo NagataReviewed-by: Tatsuo IshiiDiscussion:https://postgr.es/m/20180907180504.1ff19e1675bb44a67e9c7ab1@sraoss.co.jp
1 parente5f1bb9 commit514a731

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

‎src/backend/commands/extension.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -683,8 +683,6 @@ read_extension_script_file(const ExtensionControlFile *control,
683683
/*
684684
* Execute given SQL string.
685685
*
686-
* filename is used only to report errors.
687-
*
688686
* Note: it's tempting to just use SPI to execute the string, but that does
689687
* not work very well. The really serious problem is that SPI will parse,
690688
* analyze, and plan the whole string before executing any of it; of course
@@ -694,7 +692,7 @@ read_extension_script_file(const ExtensionControlFile *control,
694692
* could be very long.
695693
*/
696694
staticvoid
697-
execute_sql_string(constchar*sql,constchar*filename)
695+
execute_sql_string(constchar*sql)
698696
{
699697
List*raw_parsetree_list;
700698
DestReceiver*dest;
@@ -921,7 +919,7 @@ execute_extension_script(Oid extensionOid, ExtensionControlFile *control,
921919
/* And now back to C string */
922920
c_sql=text_to_cstring(DatumGetTextPP(t_sql));
923921

924-
execute_sql_string(c_sql,filename);
922+
execute_sql_string(c_sql);
925923
}
926924
PG_CATCH();
927925
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp