-} while(0)
-
-
-#define PA_CHECK_VALIDITY_RETURN_ANY(context, expression, error, value) do { \
- if (!(expression)) { \
- pa_context_set_error((context), (error)); \
- return value; \
- } \
-} while(0)
-
-#define PA_CHECK_VALIDITY_RETURN_NULL(context, expression, error) PA_CHECK_VALIDITY_RETURN_ANY(context, expression, error, NULL)
-
-void pa_init_proplist(pa_proplist *p);
+ } while(false)
+
+#define PA_CHECK_VALIDITY_RETURN_ANY(context, expression, error, value) \
+ do { \
+ if (!(expression)) { \
+ pa_context_set_error((context), (error)); \
+ return value; \
+ } \
+ } while(false)
+
+#define PA_CHECK_VALIDITY_RETURN_NULL(context, expression, error) \
+ PA_CHECK_VALIDITY_RETURN_ANY(context, expression, error, NULL)
+
+#define PA_FAIL(context, error) \
+ do { \
+ return -pa_context_set_error((context), (error)); \
+ } while(false)
+
+#define PA_FAIL_RETURN_ANY(context, error, value) \
+ do { \
+ pa_context_set_error((context), (error)); \
+ return value; \
+ } while(false)
+
+#define PA_FAIL_RETURN_NULL(context, error) \
+ PA_FAIL_RETURN_ANY(context, error, NULL)
+
+void pa_ext_device_manager_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
+void pa_ext_device_restore_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
+void pa_ext_stream_restore_command(pa_context *c, uint32_t tag, pa_tagstruct *t);
+
+bool pa_mainloop_is_our_api(pa_mainloop_api*m);