OSI/MHS Management Programming Manual
Examples
OSI/MHS Management Programming Manual—424824-001
C-41
Example in C
 if (!error)
 {
 send_password_response (PASSW_OK_RSP, NULL);
 return;
 }
 else
 {
 send_password_response (PASSW_ERROR_RSP, NULL);
 return;
 }
} /* end process_ms_alter_appl */
/***************************************************************************/
/* Function: process_ms_delete_appl */
/* Usage : process_ms_delete_appl (req_buf) */
/* Parameters: req_buf INPUT */
/*-------------------------------------------------------------------------*/
/* Process the DELETE APPL request from the MHSMGR. Extract the attributes */
/* from the request and call delete_mspwtabl_row to delete 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_APPL_ORNAME Required */
/***************************************************************************/
void process_ms_delete_appl (char *req_buf)
{
 short *req_buf_s = (short *)req_buf;
 int error;
 zmhs_ddl_appl_name_def appl_name;
 zmhs_ddl_appl_orname_def appl_orname;
 error = SSGET (req_buf_s,
 (short *)&zmhs_map_appl_name,
 (char *)&appl_name);
 if (error)
 {
 printf ("SSGET procedure error - %d\n", error);
 send_password_response (PASSW_ERROR_RSP, NULL);
 return;
 }
 error = SSGET (req_buf_s,
 (short *)&zmhs_map_appl_orname,
 (char *)&appl_orname);
 if (error)
 {
 printf ("SSGET procedure error - %d\n", error);
 send_password_response (PASSW_ERROR_RSP, NULL);
 return;
 }
 if (!error)
 {
 error = delete_mspwtabl_row (&appl_name);
 if (error)
 {
 printf ("SQL Error deleting MSPWTABL row - %d\n", error);
 }
 }
 if (!error)
 {
 send_password_response (PASSW_OK_RSP, NULL);
 return;










