aboutsummaryrefslogtreecommitdiff
path: root/include/wydawca/wydawca.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/wydawca/wydawca.h')
-rw-r--r--include/wydawca/wydawca.h30
1 files changed, 14 insertions, 16 deletions
diff --git a/include/wydawca/wydawca.h b/include/wydawca/wydawca.h
index 5af2996..a541157 100644
--- a/include/wydawca/wydawca.h
+++ b/include/wydawca/wydawca.h
@@ -40,8 +40,9 @@ extern char *wy_syslog_tag; /* Syslog tag */
# define WY_PRINTFLIKE(fmt,narg) __attribute__ ((__format__ (__printf__, fmt, narg)))
#endif
-void wy_log(int prio, char *fmt, ...) WY_PRINTFLIKE(2, 3);
-void wy_dbg(char *fmt, ...) WY_PRINTFLIKE(1, 2);
+void wy_log(int prio, char const *fmt, ...) WY_PRINTFLIKE(2, 3);
+void wy_vlog(int prio, char const *fmt, va_list ap);
+void wy_dbg(char const *fmt, ...) WY_PRINTFLIKE(1, 2);
#define wy_debug(l,c) do { \
if (wy_debug_level >= (l)) \
wy_dbg c; \
@@ -91,24 +92,21 @@ struct wy_user {
char *fpr;
};
-typedef struct wy_triplet *wy_triplet_t;
+typedef struct wy_triplet wy_triplet_t;
-const char *wy_triplet_project(wy_triplet_t trp);
-struct wy_user *wy_triplet_get_uploaders(wy_triplet_t trp);
-struct wy_user *wy_triplet_get_admins(wy_triplet_t trp);
-struct wy_user *wy_triplet_get_uploader(wy_triplet_t trp);
+const char *wy_triplet_project(wy_triplet_t *trp);
+struct wy_user *wy_triplet_get_uploaders(wy_triplet_t *trp);
+struct wy_user *wy_triplet_get_admins(wy_triplet_t *trp);
+struct wy_user *wy_triplet_get_uploader(wy_triplet_t *trp);
-struct wy_metadef {
- char *kw;
- char *value;
- const char *(*expand) (struct wy_metadef *, void *);
- char *storage;
- void *data;
+struct wy_vardef {
+ char const *name;
+ int (*expand)(char **ret, struct wy_triplet *trp);
};
+char *wy_triplet_expand_param(const char *tmpl, struct wy_triplet *trp,
+ struct wy_vardef *xmeta);
char *wy_expand_stats(const char *tmpl);
-char *wy_triplet_expand_param(const char *tmpl, struct wy_triplet const *trp,
- struct wy_metadef *xmeta);
-
int wy_stat_mask_p(unsigned long mask);
+int wy_expand_copy(char **ret, char const *s);

Return to:

Send suggestions and report system problems to the System administrator.