diff options
author | jbj <devnull@localhost> | 2003-04-02 21:16:26 +0000 |
---|---|---|
committer | jbj <devnull@localhost> | 2003-04-02 21:16:26 +0000 |
commit | 95f01d39a57c3c3d8ebf80cfd78e67c550dc32e5 (patch) | |
tree | d8eaa0d6c4bb93c5c12a18a3e066de0d68e3aae2 /rpmio/rpmsq.h | |
parent | 1f366d6a00d1cf8dc08a40fe789a1b68b4b80a5a (diff) | |
download | librpm-tizen-95f01d39a57c3c3d8ebf80cfd78e67c550dc32e5.tar.gz librpm-tizen-95f01d39a57c3c3d8ebf80cfd78e67c550dc32e5.tar.bz2 librpm-tizen-95f01d39a57c3c3d8ebf80cfd78e67c550dc32e5.zip |
Splint clean.
CVS patchset: 6729
CVS date: 2003/04/02 21:16:26
Diffstat (limited to 'rpmio/rpmsq.h')
-rw-r--r-- | rpmio/rpmsq.h | 55 |
1 files changed, 40 insertions, 15 deletions
diff --git a/rpmio/rpmsq.h b/rpmio/rpmsq.h index 04fcf5e84..6d80f7853 100644 --- a/rpmio/rpmsq.h +++ b/rpmio/rpmsq.h @@ -6,18 +6,23 @@ * */ -#include <pthread.h> -#include <signal.h> -#include <sys/signal.h> -#include <search.h> /* XXX insque(3)/remque(3) protos. */ - #include <rpmsw.h> +/** + */ typedef struct rpmsig_s * rpmsig; +/** + */ typedef struct rpmsqElem * rpmsq; -typedef void (*rpmsqAction_t) (int signum, siginfo_t *info, void *context) +/** + * Default signal handler prototype. + * @param signum signal number + * @param info (siginfo_t) signal info + * @param context signal context + */ +typedef void (*rpmsqAction_t) (int signum, void * info, void * context) /*@*/; /*@-redecl@*/ @@ -44,8 +49,10 @@ struct rpmsqElem { pthread_cond_t cond; }; +/*@-exportlocal@*/ /*@unchecked@*/ extern rpmsq rpmsqQueue; +/*@=exportlocal@*/ /*@unchecked@*/ extern sigset_t rpmsqCaught; @@ -55,21 +62,38 @@ extern sigset_t rpmsqCaught; #endif /** + * Insert node into from queue. + * @param elem node to link + * @param prev previous node from queue + * @return 0 on success */ +/*@-exportlocal@*/ int rpmsqInsert(/*@null@*/ void * elem, /*@null@*/ void * prev) - /*@globals rpmsqQueue @*/ - /*@modifies elem, rpmsqQueue @*/; + /*@modifies elem @*/; +/*@=exportlocal@*/ /** + * Remove node from queue. + * @param elem node to link + * @return 0 on success */ +/*@-exportlocal@*/ int rpmsqRemove(/*@null@*/ void * elem) - /*@modifies elem @*/; + /*@globals fileSystem, internalState @*/ + /*@modifies elem, fileSystem, internalState @*/; +/*@=exportlocal@*/ /** + * Default signal handler. + * @param signum signal number + * @param info (siginfo_t) signal info + * @param context signal context */ -void rpmsqAction(int signum, siginfo_t * info, void * context) - /*@globals rpmsqCaught, fileSystem @*/ - /*@modifies rpmsqCaught, fileSystem @*/; +/*@-exportlocal@*/ +void rpmsqAction(int signum, void * info, void * context) + /*@globals rpmsqCaught, errno, fileSystem @*/ + /*@modifies rpmsqCaught, errno, fileSystem @*/; +/*@=exportlocal@*/ /** * Enable or disable a signal handler. @@ -106,14 +130,15 @@ pid_t rpmsqWait(rpmsq sq) * @return 0 on success */ int rpmsqThread(void * (*start) (void * arg), void * arg) - /*@globals fileSystem, internalState @*/ - /*@modifies fileSystem, internalState @*/; + /*@globals internalState @*/ + /*@modifies internalState @*/; /** * Execute a command, returning its status. */ int rpmsqExecve (const char ** argv) - /*@*/; + /*@globals fileSystem, internalState @*/ + /*@modifies fileSystem, internalState @*/; #ifdef __cplusplus } |