version 1.1.1.1, 2008/08/28 13:18:30
|
version 1.1.1.1.2.2, 2008/10/13 18:22:01
|
Line 1
|
Line 1
|
|
/************************************************************************* |
|
* (C) 2008 AITNET ltd - Sofia/Bulgaria - <misho@aitbg.com> |
|
* by Michael Pounov <misho@openbsd-bg.org> |
|
* |
|
* $Author$ |
|
* $Id$ |
|
* |
|
*************************************************************************/ |
#include "global.h" |
#include "global.h" |
#include "aitsess.h" |
#include "aitsess.h" |
|
|
Line 387 inline void ipc_detachSession(tagSess * __restrict s)
|
Line 395 inline void ipc_detachSession(tagSess * __restrict s)
|
shmdt(s->addr); |
shmdt(s->addr); |
s->addr = NULL; |
s->addr = NULL; |
} |
} |
|
} |
|
|
|
/* |
|
* isAttached() Check for mapped/(attached) shared memory |
|
* @s = Session item |
|
* return: -1 null session item, 0 not attached, 1 attached memory |
|
*/ |
|
inline int isAttached(tagSess * __restrict s) |
|
{ |
|
if (!s) |
|
return -1; |
|
|
|
return (s->addr ? 1 : 0); |
} |
} |
|
|
|
|