Ask a Question related to Coldfusion Component Development, Design and Development.
-
Jason #1
Null pointer error instantiating CFC
Hi folks,
I'm having a problem on a server, in which attempts to instantiate a
CFC result in a null pointer error. I was promoting an application
from a development server to the production server (which happens to be
TWO servers, behind a load balancer), and the app wouldn't work. First
time a CFC is instantiated, it dies (this happens in the
Application.cfm, so it's immediate.) The environment is CFMX6.1 on
Solaris 5.8. To ease troubleshooting, I've reduced the bug to the most
simple test case I could:
Application.cfm
---------------
This file is empty, just to make sure another - higher -
Application.cfm file isn't getting picked up.
talker.cfc
----------
<cfcomponent>
<cffunction name="echo">
<cfargument name="value">
<cfoutput>#arguments.value#</cfoutput>
</cffunction>
</cfcomponent>
index.cfm
---------
<!--- <cfobject name="talker" component="talker"> --->
<cfset talker = CreateObject("component", "talker")>
<cfoutput>
<cfset talker.echo("1")>
<cfset talker.echo("2")>
<cfset talker.echo("3")>
<cfset talker.echo("4")>
</cfoutput>
When I run this on my Dev server, I get the desired output ("1 2 3 4").
On the production server (and both are doing the same thing) I get:
-------------------------------------------------------
The system has attempted to use an undefined value, which usually
indicates a programming error, either in your code or some system code.
Null Pointers are another name for undefined values.
The error occurred in /inside3/htdocs/sapp/isarp/test/test/index.cfm:
line 2
1 : <!--- <cfobject name="talker" component="talker"> --->
2 : <cfset talker = CreateObject("component", "talker")>
3 : <cfoutput>
4 : <cfset talker.echo("1")>
-------------------------------------------------------
I get the same error, whether I use the <cfobject> tag, or the
CreateObject function. Different line number, of course.
The same test case has been put on three other servers as well (two in
the same load balanced configuration, the other running 'solo') and it
has worked fine on all of them. I'm relatively sure it's something to
do with these two servers, but don't have any good ideas. Further, the
fact that it happens on both production servers (rather than just one)
behind the load balancer is slightly curious.
Does anyone have any ideas what might be wrong here?
Thanks,
Jason
Jason Guest
-
#38648 [Csd->Bgs]: NULL pointer leads to core dump in "php_stream_bucket_unlink()"
ID: 38648 Updated by: pollita@php.net Reported By: songmaqd at hotmail dot com -Status: Closed +Status: ... -
#38649 [Asn->Csd]: NULL pointer leads to core dump in "php_stream_bucket_unlink()"
ID: 38649 Updated by: pollita@php.net Reported By: songmaqd at hotmail dot com -Status: Assigned +Status: ... -
Administrator error - null pointer
I have received an error message all of a sudden in my administrator, and it is attached below. When I try to access the caching and memory... -
Null pointer when instantiating CFC
Hi folks, I'm having a problem on a server, in which attempts to instantiate a CFC result in a null pointer error. I was promoting an... -
Error instantiating RSACryptoServiceProvider
Please help me, I'm bleeding here! Problem outlined below: Ignus "Ignus Fast" <junk@no.com> wrote in message...



Reply With Quote

