Search Postgresql Archives

fmgr_info_cxt_security() modifies variable?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, I'm calling an arbitrary user-defined function from the backend. Although I can do it via FunctionCallInvoke, I have a weird problem when calling fmgr_info. The call results in a argument variable (eventType) being cleared. A gdb hardware watch says that the variable is modified by this line (185) in fmgr.c: finfo->fn_extra = NULL; Any ideas of what is happening? For simplicity, in the following snippet I have hardcoded foid to some (PGPSQL) function id and removed the rest of the call-related statements.

static void execEventTypeFunc(char *eventType, Oid funcId)
{
	FmgrInfo *finfo;
	FunctionCallInfoData fcinfo;
	Datum           result;
Oid foid = 17283;
	finfo = (FmgrInfo *) palloc0(sizeof(FmgrInfo));

fmgr_info(foid, finfo);
	...
}

Thanks,

Luis

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
      choose an index scan if your joining column's datatypes do not
      match


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux