summaryrefslogtreecommitdiff
path: root/rpmio/rpmsw.h
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2003-04-08 21:42:55 +0000
committerjbj <devnull@localhost>2003-04-08 21:42:55 +0000
commit783219a8325bca538d21c367f9c523a79dbcb011 (patch)
tree4ae43dc0fa37c05931ff370a09f05fcfb14a1e21 /rpmio/rpmsw.h
parentf60ec855de0d6bfd29325fcb73b2901780e72e3d (diff)
downloadrpm-783219a8325bca538d21c367f9c523a79dbcb011.tar.gz
rpm-783219a8325bca538d21c367f9c523a79dbcb011.tar.bz2
rpm-783219a8325bca538d21c367f9c523a79dbcb011.zip
fix: prevent segfault if malicious server sends 1 GB of data through ftpNLST.
fix: rpmal could segfault under obscure conditions. Use array, not individual structures, for rpmsw{Enter,Exit} timestamps. CVS patchset: 6735 CVS date: 2003/04/08 21:42:55
Diffstat (limited to 'rpmio/rpmsw.h')
-rw-r--r--rpmio/rpmsw.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/rpmio/rpmsw.h b/rpmio/rpmsw.h
index 8bcedf274..3cae71198 100644
--- a/rpmio/rpmsw.h
+++ b/rpmio/rpmsw.h
@@ -77,7 +77,7 @@ rpmtime_t rpmswInit(void)
* @param rc -1 clears usec counter
* @return 0 always
*/
-int rpmswEnter(rpmop op, ssize_t rc)
+int rpmswEnter(/*@null@*/ rpmop op, ssize_t rc)
/*@globals internalState @*/
/*@modifies *op, internalState @*/;
@@ -87,7 +87,7 @@ int rpmswEnter(rpmop op, ssize_t rc)
* @param rc per-operation data (e.g. bytes transferred)
* @return cumulative usecs for operation
*/
-rpmtime_t rpmswExit(rpmop op, ssize_t rc)
+rpmtime_t rpmswExit(/*@null@*/ rpmop op, ssize_t rc)
/*@globals internalState @*/
/*@modifies op, internalState @*/;
@@ -97,7 +97,7 @@ rpmtime_t rpmswExit(rpmop op, ssize_t rc)
* @param from operation statistics
* @return cumulative usecs for operation
*/
-rpmtime_t rpmswAdd(rpmop to, rpmop from)
+rpmtime_t rpmswAdd(/*@null@*/ rpmop to, /*@null@*/ rpmop from)
/*@modifies to @*/;
/** \ingroup rpmio