diff options
author | Pixel <Pixel> | 2001-11-26 23:11:40 +0000 |
---|---|---|
committer | Pixel <Pixel> | 2001-11-26 23:11:40 +0000 |
commit | 3baa9d168c02a8734b95d1cc467601b6aaf2f6e4 (patch) | |
tree | 6c254e9d75dee5a1e305283788fea3d3fff2a445 /include/Exceptions.h | |
parent | 3aa63fcbddbce8762ad0f3f54d90ad985c0f9c41 (diff) |
Big job here. Many bugs out. Hurray!!
Diffstat (limited to 'include/Exceptions.h')
-rw-r--r-- | include/Exceptions.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/include/Exceptions.h b/include/Exceptions.h index 090ace9..e72a8a2 100644 --- a/include/Exceptions.h +++ b/include/Exceptions.h @@ -34,10 +34,11 @@ class GeneralException; -char * xstrdup(const char *) throw (GeneralException); -void * xmalloc(ssize_t) throw (GeneralException); +char * xstrdup(const char *); +void * xmalloc(size_t) throw (GeneralException); void xfree(void *&); -void * xrealloc(void *, size_t) throw (GeneralException); +void * xrealloc(void *, size_t); +int xpipe(int *, int = 0) throw (GeneralException); // On prédéfinit la classe String, pour éviter // les deadlocks de compilation... @@ -54,6 +55,9 @@ class Base { static void * realloc(void * p, size_t s) { return xrealloc(p, s); } + static void * calloc(size_t n, size_t s) { + return xmalloc(n * s); + } void * operator new(size_t s) { return xmalloc(s); } @@ -69,6 +73,9 @@ class Base { static void free(char *& p) { xfree((void *) p); } + static int pipe(int * p, int flag = 0) { + return xpipe(p); + } }; class GeneralException : public Base { |