diff options
| author | 2023-12-28 06:40:07 -0600 | |
|---|---|---|
| committer | 2023-12-28 06:40:07 -0600 | |
| commit | cfe01c9f8b7ac0d82e694323b60fc172e0c35a48 (patch) | |
| tree | 6f02144b38fcb2a4c5116e412f9ed4b0cc711728 /src/version.h | |
| parent | add cheap SHA1 implementation (diff) | |
[wip] version stuff
Diffstat (limited to 'src/version.h')
| -rw-r--r-- | src/version.h | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/src/version.h b/src/version.h index b3f640f..246e346 100644 --- a/src/version.h +++ b/src/version.h @@ -1,10 +1,38 @@ #ifndef L2SU_VERSION_H_INCLUDED #define L2SU_VERSION_H_INCLUDED +#include "digest/digest.h" +#include <time.h> +#include <jansson.h> + +enum { + VERSION_SUCCESS, + VERSION_EFORMAT, + VERSION_EJSON, + VERSION_EALLOC, + VERSION_ERRNO, + VERSION_EUNSPEC +}; + struct l2_version_remote { - + struct l2_version_remote *next; + struct l2_version_remote *prev; + + char *id; + char *type; + char *url; + + l2_sha1_digest_t sha1; + json_int_t compliance_level; + + time_t update_time; + time_t release_time; }; +extern const char *const l2_version__messages[]; + +#define l2_version_strerror(_en) l2_version__messages[(_en)] + unsigned l2_version_load_remote(void); unsigned l2_version_load_local(void); |
