Add alloca_poll_events() macro

This commit is contained in:
Andrew Bettison 2013-10-17 00:01:32 +10:30
parent fa21bec880
commit e82d22d765

View File

@ -67,6 +67,7 @@ strbuf strbuf_path_join(strbuf sb, ...);
* @author Andrew Bettison <andrew@servalproject.com>
*/
strbuf strbuf_append_poll_events(strbuf sb, short events);
#define alloca_poll_events(ev) strbuf_str(strbuf_append_poll_events(strbuf_alloca(200), (ev)))
/* Append a nul-terminated string as a single-quoted shell word which, if
* expanded in a shell command line, would evaluate to the original string.