summaryrefslogtreecommitdiff
path: root/rpmio
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2003-04-01 22:26:09 +0000
committerjbj <devnull@localhost>2003-04-01 22:26:09 +0000
commit4eb5fa7dc583f7c89d3a6118f73f581300a1375e (patch)
tree3da96a2c717046e7329e966c27066a7af68ca9cf /rpmio
parentcec67caee668e6f95b1f5163b04d034d8c52fe5e (diff)
downloadlibrpm-tizen-4eb5fa7dc583f7c89d3a6118f73f581300a1375e.tar.gz
librpm-tizen-4eb5fa7dc583f7c89d3a6118f73f581300a1375e.tar.bz2
librpm-tizen-4eb5fa7dc583f7c89d3a6118f73f581300a1375e.zip
Splint fiddles.
Move OPSTAT_t to rpmsw.h. CVS patchset: 6725 CVS date: 2003/04/01 22:26:09
Diffstat (limited to 'rpmio')
-rw-r--r--rpmio/rpmio_internal.h22
1 files changed, 8 insertions, 14 deletions
diff --git a/rpmio/rpmio_internal.h b/rpmio/rpmio_internal.h
index 378e38532..4256021c0 100644
--- a/rpmio/rpmio_internal.h
+++ b/rpmio/rpmio_internal.h
@@ -102,15 +102,6 @@ typedef struct _FDSTACK_s {
} FDSTACK_t;
/** \ingroup rpmio
- * Cumulative statistics for an I/O operation.
- */
-typedef struct {
- int count; /*!< Number of operations. */
- off_t bytes; /*!< Number of bytes transferred. */
- time_t usecs; /*!< Number of ticks. */
-} OPSTAT_t;
-
-/** \ingroup rpmio
* Identify per-desciptor I/O operation statistics.
*/
enum FDSTAT_e {
@@ -126,7 +117,7 @@ enum FDSTAT_e {
typedef /*@abstract@*/ struct {
struct rpmsw_s create; /*!< Structure creation time. */
struct rpmsw_s begin; /*!< Operation start time. */
- OPSTAT_t ops[4]; /*!< Cumulative statistics. */
+ struct rpmop_s ops[4]; /*!< Cumulative statistics. */
} * FDSTAT_t;
/** \ingroup rpmio
@@ -365,8 +356,10 @@ void fdPush(FD_t fd, FDIO_t io, void * fp, int fdno)
/** \ingroup rpmio
*/
-/*@unused@*/ static inline void fdstat_enter(/*@null@*/ FD_t fd, int opx)
- /*@modifies fd @*/
+/*@unused@*/ static inline
+void fdstat_enter(/*@null@*/ FD_t fd, int opx)
+ /*@globals internalState @*/
+ /*@modifies fd, internalState @*/
{
if (fd == NULL || fd->stats == NULL) return;
/*@-boundswrite@*/
@@ -379,7 +372,8 @@ void fdPush(FD_t fd, FDIO_t io, void * fp, int fdno)
*/
/*@unused@*/ static inline
void fdstat_exit(/*@null@*/ FD_t fd, int opx, ssize_t rc)
- /*@modifies fd @*/
+ /*@globals internalState @*/
+ /*@modifies fd, internalState @*/
{
struct rpmsw_s end;
if (fd == NULL) return;
@@ -416,7 +410,7 @@ void fdstat_print(/*@null@*/ FD_t fd, const char * msg, FILE * fp)
if (fd == NULL || fd->stats == NULL) return;
for (opx = 0; opx < 4; opx++) {
- OPSTAT_t *ops = &fd->stats->ops[opx];
+ rpmop ops = &fd->stats->ops[opx];
if (ops->count <= 0) continue;
switch (opx) {
case FDSTAT_READ: