diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2021-09-13 14:40:06 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2021-09-13 14:40:06 +0100 |
commit | e89fc350172a710d97eb301d8dfc9a9667610ed3 (patch) | |
tree | 1fbdf4a4b2091f9993aa885568b4ed819f8ccd1b /src/libutil/upstream.h | |
parent | bceef07323959f7e1a6bf09248c1ee08d5923bd0 (diff) | |
download | rspamd-e89fc350172a710d97eb301d8dfc9a9667610ed3.tar.gz rspamd-e89fc350172a710d97eb301d8dfc9a9667610ed3.zip |
[Minor] Allow to capture upstream object
Diffstat (limited to 'src/libutil/upstream.h')
-rw-r--r-- | src/libutil/upstream.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/libutil/upstream.h b/src/libutil/upstream.h index 89bcd9b52..72a768892 100644 --- a/src/libutil/upstream.h +++ b/src/libutil/upstream.h @@ -299,6 +299,18 @@ struct upstream *rspamd_upstream_get_except (struct upstream_list *ups, */ void rspamd_upstream_reresolve (struct upstream_ctx *ctx); +/** + * Share ownership on upstream + * @param up + * @return + */ +struct upstream* rspamd_upstream_ref (struct upstream *up); +/** + * Unshare ownership on upstream + * @param up + */ +void rspamd_upstream_unref (struct upstream *up); + #ifdef __cplusplus } #endif |