OSI/MHS Management Programming Manual
Examples
OSI/MHS Management Programming Manual—424824-001
C-39
Example in C
 ua_osi_address.zpselector.zlength = -1;
 ua_osi_address.zsselector.zlength = -1;
 ua_osi_address.ztselector.zlength = -1;
 ua_osi_address.znsap.zlength = -1;
 }
 if (error)
 {
 printf ("SSGET procedure error - %d\n", error);
 send_password_response (PASSW_ERROR_RSP, NULL);
 return;
 }
 if (!error)
 {
 error = add_mspwtabl_row (&appl_name,
 &passw,
 &appl_orname,
 &ua_osi_address);
 if (error)
 {
 printf ("SQL Error adding row to MSPWTABL - %d\n", error);
 }
 }
 if (!error)
 {
 send_password_response (PASSW_OK_RSP, NULL);
 return;
 }
 else
 {
 send_password_response (PASSW_ERROR_RSP, NULL);
 return;
 }
} /* end process_ms_add_appl */
/***************************************************************************/
/* Function: process_ms_alter_appl */
/* Usage : process_ms_alter_appl (req_buf) */
/* Parameters: req_buf INPUT */
/*-------------------------------------------------------------------------*/
/* Process the ALTER APPL request from the MHSMGR. Extract the attributes */
/* from the request and call alter_mspwtabl_row to alter the row in */
/* MSPWTABL. If all goes well, send an OK response, else send an error */
/* response. */
/* Tokens: */
/* ZMHS_MAP_APPL_NAME Required */
/* ZMHS_MAP_PASSW Optional */
/* ZMHS_MAP_APPL_ORNAME Required */
/* ZMHS_MAP_UA_OSI_ADDRESS Optional */
/***************************************************************************/
void process_ms_alter_appl (char *req_buf)
{
 short *req_buf_s = (short *)req_buf;
 int error;
 zmhs_ddl_appl_name_def appl_name;
 zmhs_ddl_passw_def passw;
 zmhs_ddl_appl_orname_def appl_orname;
 zmhs_ddl_ua_osi_address_def ua_osi_address;
 error = SSGET (req_buf_s,
 (short *)&zmhs_map_appl_name,
 (char *)&appl_name);
 if (error)










