⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 closeconnection.c

📁 适合于Unix/Linux下的一个持久数据库连接池
💻 C
字号:
// Copyright (c) 1999-2001  David Muse// See the file COPYING for more information#include <sqlrconnection.h>void sqlrconnection_svr::closeConnection() {	// decrement the connection counter	if (decrementonclose && cfgfl->getDynamicScaling() &&						semset && idmemory) {		decrementConnectionCount();	}	// deregister and close the handoff socket if necessary	if (cfgfl->getPassDescriptor()) {		deRegisterForHandoff(tmpdir->getString());	}	// close the cursors	closeCursors(true);	// try to log out	#ifdef SERVER_DEBUG	debugPrint("connection",0,"logging out...");	#endif	logOutUpdateStats();	#ifdef SERVER_DEBUG	debugPrint("connection",0,"done logging out");	#endif	// clear the pool	#ifdef SERVER_DEBUG	debugPrint("connection",0,"removing all sockets...");	#endif	removeAllFileDescriptors();	#ifdef SERVER_DEBUG	debugPrint("connection",0,"done removing all sockets");	#endif	// close, clean up all sockets	#ifdef SERVER_DEBUG	debugPrint("connection",0,"deleting unix socket...");	#endif	delete serversockun;	#ifdef SERVER_DEBUG	debugPrint("connection",0,"done deleting unix socket");	#endif	#ifdef SERVER_DEBUG	debugPrint("connection",0,"deleting inetsockets...");	#endif	for (uint64_t index=0; index<serversockincount; index++) {		delete serversockin[index];	}	delete[] serversockin;	#ifdef SERVER_DEBUG	debugPrint("connection",0,"done deleting inet socket");	#endif}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -