void pre_process_post_filename( char *buffer )
{
int i, start, stop, j, k, index, next;
for( i=0, start=0; i<RECV_BUFFER_SIZE; i++ )
{
if( buffer[i] == '=' )
{
start = i;
}
}
if( !start )
{
printf ("in !start");
return;
}
// From start to buffer[i] == 0 is the full form string, it may contain multiple forms
for( i=start, stop=0, start=0; i<RECV_BUFFER_SIZE; i++ )
{
if(buffer[i] == '=')
{
buffer[i] = 0;
if( !start )
start = i+1;
else
{
stop = i;
next = i+1;
}
continue;
}
if( buffer[i] == 0 )
{
stop = i;
next = 0;
}
if( stop )
{
process_post_form( &buffer[start]);
if( !next )
break;
else
{
start = 0;
stop = 0;
i++;
}
}
}
}
void process_post_form( char *form_string )
{
int i, j, index;
int num_ands, cur_and, and_count;
int start, end;
int is_next;
char *this_temp_form_string, *next_temp_form_string;
next_temp_form_string = form_string;
this_temp_form_string = next_temp_form_string;
if ((char)(*(next_temp_form_string-2))=='d') //Passwd
{
(forms[9].func)(this_temp_form_string); /* 9 because index of Passwd is 9 in freescale_static_ffs_utils.c*/
}
If ((char)(*(next_temp_form_string-2))=='o') //chgpwo
{
(forms[10].func)(this_temp_form_string); /* 10 because index of chgpwo is 10 in freescale_static_ffs_utils.c*/
}
if((char)(*(next_temp_form_string-2))=='n') //chgpwn
{
(forms[11].func)(this_temp_form_string); /* 11 because index of chgpwn is 11 in freescale_static_ffs_utils.c*/
}
}
Note: Passwd, chgpwd and chgpwn are the name of variables in html page.Ignore?xml:namespace prefix = o ns = "urn:schemas-microsoft-com
ffice
ffice" /> .It showed up during preview post.Replace the other two icons by ).