aboutsummaryrefslogtreecommitdiffstats
path: root/include/out_buf.h
diff options
context:
space:
mode:
authorlloyd <[email protected]>2008-04-12 16:17:44 +0000
committerlloyd <[email protected]>2008-04-12 16:17:44 +0000
commitdabde92a24671700ac2150c938587c3efd505499 (patch)
tree3e5dc688be68d6c84fad7a6c99fdbd98d93b60c1 /include/out_buf.h
parent9cbdc7ee564c802781b82ba907b7dfb187fa52e8 (diff)
Modify areas that still assumed Pipe::message_id was exactly a u32bit.
This was done by replacing Pipe::message_id with a completely opaque type and adding only the necessary operations. In this revision Pipe::message_id does remain a u32bit. However it may become an opaque type in the future. Move the Invalid_Message_Number exception to Pipe since that is the only piece of code which throws it.
Diffstat (limited to 'include/out_buf.h')
-rw-r--r--include/out_buf.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/include/out_buf.h b/include/out_buf.h
index 8965e3895..1e169b9bc 100644
--- a/include/out_buf.h
+++ b/include/out_buf.h
@@ -7,6 +7,7 @@
#define BOTAN_OUTPUT_BUFFER_H__
#include <botan/types.h>
+#include <botan/pipe.h>
#include <deque>
namespace Botan {
@@ -17,22 +18,22 @@ namespace Botan {
class Output_Buffers
{
public:
- u32bit read(byte[], u32bit, u32bit);
- u32bit peek(byte[], u32bit, u32bit, u32bit) const;
- u32bit remaining(u32bit) const;
+ u32bit read(byte[], u32bit, Pipe::message_id);
+ u32bit peek(byte[], u32bit, u32bit, Pipe::message_id) const;
+ u32bit remaining(Pipe::message_id) const;
void add(class SecureQueue*);
void retire();
- u32bit message_count() const;
+ Pipe::message_id message_count() const;
Output_Buffers();
~Output_Buffers();
private:
- class SecureQueue* get(u32bit) const;
+ class SecureQueue* get(Pipe::message_id) const;
std::deque<SecureQueue*> buffers;
- u32bit offset;
+ Pipe::message_id offset;
};
}