mirror of
https://github.com/obgm/libcoap.git
synced 2026-11-07 18:12:55 +03:00
resource.c: Implement the coap_resource_notify_observers() function
Reuse coap_resource_set_dirty() and make coap_resource_set_dirty() call coap_resource_notify_observers().
This commit is contained in:
1 parent
5ecc164caa
commit
ac97aeb9bc
1 file changed
+5
@@ -757,6 +757,11 @@ coap_notify_observers(coap_context_t *context, coap_resource_t *r) {
|
||||
|
||||
int
|
||||
coap_resource_set_dirty(coap_resource_t *r, const str *query) {
|
||||
return coap_resource_notify_observers(r, query);
|
||||
}
|
||||
|
||||
int
|
||||
coap_resource_notify_observers(coap_resource_t *r, const str *query) {
|
||||
if (!r->observable)
|
||||
return 0;
|
||||
if (query) {
|
||||
|
||||
Reference in new issue
Block a user