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

Commit274dfdb

Browse files
committed
Tweak clean_encoding_name() API to avoid need to cast away const.
Kris Jurka
1 parent6ee2a3b commit274dfdb

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

‎src/backend/utils/mb/encnames.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Encoding names and routines for work with it. All
33
* in this file is shared bedween FE and BE.
44
*
5-
* $PostgreSQL: pgsql/src/backend/utils/mb/encnames.c,v 1.33 2007/04/15 10:56:25 ishii Exp $
5+
* $PostgreSQL: pgsql/src/backend/utils/mb/encnames.c,v 1.34 2007/04/16 18:50:49 tgl Exp $
66
*/
77
#ifdefFRONTEND
88
#include"postgres_fe.h"
@@ -460,10 +460,10 @@ pg_valid_server_encoding(const char *name)
460460
* ----------
461461
*/
462462
staticchar*
463-
clean_encoding_name(char*key,char*newkey)
463+
clean_encoding_name(constchar*key,char*newkey)
464464
{
465-
char*p,
466-
*np;
465+
constchar*p;
466+
char*np;
467467

468468
for (p=key,np=newkey;*p!='\0';p++)
469469
{
@@ -508,7 +508,7 @@ pg_char_to_encname_struct(const char *name)
508508
errmsg("encoding name too long")));
509509
#endif
510510
}
511-
key=clean_encoding_name((char*)name,buff);
511+
key=clean_encoding_name(name,buff);
512512

513513
while (last >=base)
514514
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp