RAOP_API raop_t *raop_init(raop_callbacks_t *callbacks, const char *pemkey);
RAOP_API raop_t *raop_init_from_keyfile(raop_callbacks_t *callbacks, const char *keyfile);
+RAOP_API int raop_is_running(raop_t *raop);
+
RAOP_API int raop_start(raop_t *raop, unsigned short *port, const char *hwaddr, int hwaddrlen, const char *password);
RAOP_API void raop_stop(raop_t *raop);
return 1;
}
+int
+httpd_is_running(httpd_t *httpd)
+{
+ int running;
+
+ assert(httpd);
+
+ MUTEX_LOCK(httpd->run_mutex);
+ running = httpd->running || !httpd->joined;
+ MUTEX_UNLOCK(httpd->run_mutex);
+
+ return running;
+}
+
void
httpd_stop(httpd_t *httpd)
{
httpd_t *httpd_init(logger_t *logger, httpd_callbacks_t *callbacks, int max_connections, int use_rtsp);
+int httpd_is_running(httpd_t *httpd);
+
int httpd_start(httpd_t *httpd, unsigned short *port);
void httpd_stop(httpd_t *httpd);
}
}
+int
+raop_is_running(raop_t *raop)
+{
+ assert(raop);
+
+ return httpd_is_running(raop->httpd);
+}
+
int
raop_start(raop_t *raop, unsigned short *port, const char *hwaddr, int hwaddrlen, const char *password)
{