dcsimg
jsp/servlet/jni
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Tulasi_Bathula
Posted On:   Tuesday, January 29, 2002 03:39 AM

Hi, I have a jsp(request.jsp) page where there is a button with name 'go'. I have a servlet abc.java which is there in WEB-IN/classes In the same file i have a class xyz which contains a native call public native String Ccall(String param1) I am loading the native method in the servlet and calling the native method passing the value of string, where the string value is "go" xyz tf=new xyz(); i=tf.Ccall(param1); (i am finally passing this to response to response.jsp) In the .c file i am just giving an if loop i.e if(str=="go") FILE *fp; fp=fopen("myfile.c","w"); close(fp); So the problem is, the moment i   More>>

Hi,
I have a jsp(request.jsp) page where there is a button with name 'go'.
I have a servlet abc.java which is there in WEB-IN/classes
In the same file i have a class xyz which contains a native call
public native String Ccall(String param1)
I am loading the native method in the servlet and calling the native method passing the value of string, where the string value is "go"
xyz tf=new xyz();
i=tf.Ccall(param1);
(i am finally passing this to response to response.jsp)
In the .c file i am just giving an if loop
i.e
if(str=="go")
FILE *fp;
fp=fopen("myfile.c","w");
close(fp);

So the problem is, the moment i click go button in request.jsp
some times it is giving invoker unavailable and some times it calls the response.jsp
But myfile.c is not created
The os i am using here is RedHatLinux 6.2

Can you help?
Tulasi

   <<Less

Re: jsp/servlet/jni

Posted By:   Nathan_Meyers  
Posted On:   Wednesday, January 30, 2002 05:49 PM

Does the servlet process have write access to the directory in which it's trying to create the file?
About | Sitemap | Contact