/* * Exit closing active database connections */ void exit_gracefuly(int status) { DBDisconnect(); close(logFd); exit(status); }
/* * * Function: onTxStart * Description: 接收到CMP平台请求时处理 * Return: * Other: */ int onTxStart( char *pczExecFile ) { if( TestDBConnect() != 0 ) { DBDisconnect(); usleep(500000); DBConnect(); } /**交易开始时候重新连接*************** *****************/ return 0; }
nsresult sbIPDDevice::DeviceSpecificDisconnect() { // Disconnect the FairPlay services. FPDisconnect(); // Disconnect the Songbird device library. LibraryDisconnect(); // Disconnect the iPod preference services. PrefDisconnect(); // Disconnect the iPod database. DBDisconnect(); // Invoke the super-class. sbBaseDevice::Disconnect(); return NS_OK; }
/* * * Function: onSysEnd * Description: 系统退出时处理 * Return: * Other: */ int onSysEnd( void ) { DBDisconnect(); return 0; }