hi i have a C function ( shown below) which calls a shell script.
A command in the shell script( wput) ( shown below) should return success if it is successfully sent file over the ftp network. adn the C file should make a entry in a new file (eg: sendinfo.txt) about the sent time.
I want to know how the wput success is reported in the C ? that is how is the sent success returned to c ?
this is the C function which calls the script:
JNIEXPORT
void JNICALL
Java_DvrContact_gatherInfo( JNIEnv * env, jobject obj )
{
int i;
i=system("/home/srijith/DVR/main/dvr/gui/control/gather_upload_info"); printf("i=%d\n",i);
}
The C fuction is called by another openlazslo function. and this is the wput command in the script gather_upload_info :
.............................# scripts
...............................#scripts
.............................#scripts
/usr/bin/wput /var/tmp/$filename.tar.gz -t 1
............................#scripts
..........................#scripts
please mention the necessary changes in C and also in the script after the wput statements. I am already 5 days late on this part!
thnks in advance