--- libaitsess/inc/aitsess.h 2011/04/30 22:02:59 1.2.2.1 +++ libaitsess/inc/aitsess.h 2011/08/21 14:00:43 1.2.2.2 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitsess.h,v 1.2.2.1 2011/04/30 22:02:59 misho Exp $ +* $Id: aitsess.h,v 1.2.2.2 2011/08/21 14:00:43 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -50,6 +50,7 @@ SUCH DAMAGE. #include #include +#define SHARED_UNKNOWN 0 #define SHARED_IPC 1 #define SHARED_MAP 2 @@ -91,12 +92,13 @@ inline const char *sess_GetError(); /* * initSession() Initializing session structure, if session file not exists creating with specified tech - * @cnID = Technology using in session. SHARED_IPC IPC tech; SHARED_MAP BSD MemoryMap tech + * @pnID = Technology using in session. + SHARED_IPC IPC tech; SHARED_MAP BSD MemoryMap tech or if =NULL SHARED_IPC * @csFName = Session filename for build key and identified - * @Sess = Session item + * @Sess = Session item, if =NULL allocate memory for session after use must be free! * return: 0 OK new key created, -1 error: no memory or file not created, 1 OK key finded */ -inline int initSession(const int cnID, const char *csFName, tagSess ** __restrict Sess); +inline int initSession(int *pnID, const char *csFName, tagSess ** __restrict Sess); /* * freeSession() Free allocated memory for session item and delete session file if present name * @csFName = Session filename for delete, if NULL nothing delete