88 *
99 *
1010 * IDENTIFICATION
11- * $PostgreSQL: pgsql/src/backend/commands/typecmds.c,v 1.67 2005/01/27 23:23:56 neilc Exp $
11+ * $PostgreSQL: pgsql/src/backend/commands/typecmds.c,v 1.68 2005/03/29 03:01:30 tgl Exp $
1212 *
1313 * DESCRIPTION
1414 * The "DefineFoo" routines take the parse tree and pick out the
@@ -854,7 +854,7 @@ RemoveDomain(List *names, DropBehavior behavior)
854854static Oid
855855findTypeInputFunction (List * procname ,Oid typeOid )
856856{
857- Oid argList [FUNC_MAX_ARGS ];
857+ Oid argList [3 ];
858858Oid procOid ;
859859
860860/*
@@ -864,8 +864,6 @@ findTypeInputFunction(List *procname, Oid typeOid)
864864 * For backwards compatibility we allow OPAQUE in place of CSTRING; if we
865865 * see this, we issue a warning and fix up the pg_proc entry.
866866 */
867- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
868-
869867argList [0 ]= CSTRINGOID ;
870868
871869procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -880,8 +878,6 @@ findTypeInputFunction(List *procname, Oid typeOid)
880878return procOid ;
881879
882880/* No luck, try it with OPAQUE */
883- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
884-
885881argList [0 ]= OPAQUEOID ;
886882
887883procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -925,7 +921,7 @@ findTypeInputFunction(List *procname, Oid typeOid)
925921static Oid
926922findTypeOutputFunction (List * procname ,Oid typeOid )
927923{
928- Oid argList [FUNC_MAX_ARGS ];
924+ Oid argList [2 ];
929925Oid procOid ;
930926
931927/*
@@ -936,8 +932,6 @@ findTypeOutputFunction(List *procname, Oid typeOid)
936932 * type name; if we see this, we issue a warning and fix up the
937933 * pg_proc entry.
938934 */
939- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
940-
941935argList [0 ]= typeOid ;
942936
943937procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -951,8 +945,6 @@ findTypeOutputFunction(List *procname, Oid typeOid)
951945return procOid ;
952946
953947/* No luck, try it with OPAQUE */
954- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
955-
956948argList [0 ]= OPAQUEOID ;
957949
958950procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -995,15 +987,13 @@ findTypeOutputFunction(List *procname, Oid typeOid)
995987static Oid
996988findTypeReceiveFunction (List * procname ,Oid typeOid )
997989{
998- Oid argList [FUNC_MAX_ARGS ];
990+ Oid argList [2 ];
999991Oid procOid ;
1000992
1001993/*
1002994 * Receive functions can take a single argument of type INTERNAL, or
1003995 * two arguments (internal, oid).
1004996 */
1005- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
1006-
1007997argList [0 ]= INTERNALOID ;
1008998
1009999procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -1027,15 +1017,13 @@ findTypeReceiveFunction(List *procname, Oid typeOid)
10271017static Oid
10281018findTypeSendFunction (List * procname ,Oid typeOid )
10291019{
1030- Oid argList [FUNC_MAX_ARGS ];
1020+ Oid argList [2 ];
10311021Oid procOid ;
10321022
10331023/*
10341024 * Send functions can take a single argument of the type, or two
10351025 * arguments (data value, element OID).
10361026 */
1037- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
1038-
10391027argList [0 ]= typeOid ;
10401028
10411029procOid = LookupFuncName (procname ,1 ,argList , true);
@@ -1059,15 +1047,13 @@ findTypeSendFunction(List *procname, Oid typeOid)
10591047static Oid
10601048findTypeAnalyzeFunction (List * procname ,Oid typeOid )
10611049{
1062- Oid argList [FUNC_MAX_ARGS ];
1050+ Oid argList [1 ];
10631051Oid procOid ;
10641052
10651053/*
10661054 * Analyze functions always take one INTERNAL argument and return
10671055 * bool.
10681056 */
1069- MemSet (argList ,0 ,FUNC_MAX_ARGS * sizeof (Oid ));
1070-
10711057argList [0 ]= INTERNALOID ;
10721058
10731059procOid = LookupFuncName (procname ,1 ,argList , true);