diff options
| author | Mattias Andrée <maandree@kth.se> | 2016-03-01 18:37:05 +0100 |
|---|---|---|
| committer | Mattias Andrée <maandree@kth.se> | 2016-03-01 18:37:05 +0100 |
| commit | b0c1cae18066d0103a440894b5256939852021eb (patch) | |
| tree | b90f419aba218eedf1cc664c7269666306e6ccaf /src/zsetup.c | |
| parent | Add .gitignore (diff) | |
| download | libzahl-b0c1cae18066d0103a440894b5256939852021eb.tar.gz libzahl-b0c1cae18066d0103a440894b5256939852021eb.tar.bz2 libzahl-b0c1cae18066d0103a440894b5256939852021eb.tar.xz | |
Add zsetup, zunsetup, zinit, zfree, zswap, zsave, zload, zbits, and zlsb
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'src/zsetup.c')
| -rw-r--r-- | src/zsetup.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/zsetup.c b/src/zsetup.c new file mode 100644 index 0000000..626d6f6 --- /dev/null +++ b/src/zsetup.c @@ -0,0 +1,23 @@ +/* See LICENSE file for copyright and license details. */ +#include "internals" + +#define X(x) z_t x; +LIST_TEMPS +#undef X + +jmp_buf libzahl_jmp_buf; +int libzahl_set_up = 0; + + +void +zsetup(jmp_buf env) +{ + libzahl_jmp_buf = jmp_buf; + + if (!libzahl_set_up) { + libzahl_set_up = 1; +#define X(x) zinit(zahl_tmp_##x); + LIST_TEMPS; +#undef X + } +} |
