diff options
author | lloyd <[email protected]> | 2008-09-28 15:34:09 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2008-09-28 15:34:09 +0000 |
commit | ea32d18231b9c6c5c84b3754c4249170d3b4e4c0 (patch) | |
tree | cc179337d0594ed105768011722b9dbae105e07a /modules/es_unix/unix_cmd.h | |
parent | b841401e095cfc1aa0708689d7920eb95ece71af (diff) |
This is the first checkin to net.randombit.botan.modularized, which
has the intent of modularizing Botan's source code, and making it
much easier to add or remove various things at compile time.
In this first checkin:
Add support for nested directories in modules/ and move all the modules
into grouped directories like entropy/ or compression/
Currently this is not ideal, it will _only_ find code in
modules/*/*/modinfo.txt, while it would be much better to allow for
arbitrary nestings under modules (find modules -name modinfo.txt)
for more complicated setups.
This 'new' (OMG I've found directories!) structure allows for a more free
naming convention (no need for leading es_, ml_, etc to group names, though
some keep it for lack of a more meaningful name being obvious to me right
at the moment).
Diffstat (limited to 'modules/es_unix/unix_cmd.h')
-rw-r--r-- | modules/es_unix/unix_cmd.h | 57 |
1 files changed, 0 insertions, 57 deletions
diff --git a/modules/es_unix/unix_cmd.h b/modules/es_unix/unix_cmd.h deleted file mode 100644 index 0e187db03..000000000 --- a/modules/es_unix/unix_cmd.h +++ /dev/null @@ -1,57 +0,0 @@ -/************************************************* -* Unix Command Execution Header File * -* (C) 1999-2007 Jack Lloyd * -*************************************************/ - -#ifndef BOTAN_EXT_UNIX_CMD_H__ -#define BOTAN_EXT_UNIX_CMD_H__ - -#include <botan/types.h> -#include <botan/data_src.h> -#include <string> -#include <vector> - -namespace Botan { - -/************************************************* -* Unix Program Info * -*************************************************/ -struct Unix_Program - { - Unix_Program(const char* n, u32bit p) - { name_and_args = n; priority = p; working = true; } - - std::string name_and_args; - u32bit priority; - bool working; - }; - -/************************************************* -* Command Output DataSource * -*************************************************/ -class DataSource_Command : public DataSource - { - public: - u32bit read(byte[], u32bit); - u32bit peek(byte[], u32bit, u32bit) const; - bool end_of_data() const; - std::string id() const; - - int fd() const; - - DataSource_Command(const std::string&, - const std::vector<std::string>& paths); - ~DataSource_Command(); - private: - void create_pipe(const std::vector<std::string>&); - void shutdown_pipe(); - - const u32bit MAX_BLOCK_USECS, KILL_WAIT; - - std::vector<std::string> arg_list; - struct pipe_wrapper* pipe; - }; - -} - -#endif |