mirror of
https://github.com/obgm/libcoap.git
synced 2026-11-08 18:32:53 +03:00
Fix warnings in resource.c
Internal functions are now static. print_wellknown() is exported as coap_print_wellknown() to make it accessible from net.c and for unit tests.
This commit is contained in:
1 parent
e297a0ca76
commit
71de08ac5f
2 files changed
+6
-3
No files matched your search
@@ -335,4 +335,7 @@ coap_resource_iterator_init(coap_resource_t *resources,
|
||||
|
||||
coap_resource_t *coap_resource_next(coap_iterator_t *ri);
|
||||
|
||||
coap_print_status_t coap_print_wellknown(coap_context_t *, unsigned char *, size_t *, size_t, coap_opt_t *);
|
||||
void coap_handle_failed_notify(coap_context_t *, const coap_address_t *, const str *);
|
||||
|
||||
#endif /* _COAP_RESOURCE_H_ */
|
||||
+3
-3
@@ -177,7 +177,7 @@ coap_resource_next(coap_iterator_t *ri) {
|
||||
} \
|
||||
}
|
||||
|
||||
int
|
||||
static int
|
||||
match(const str *text, const str *pattern, int match_prefix, int match_substring) {
|
||||
assert(text); assert(pattern);
|
||||
|
||||
@@ -235,12 +235,12 @@ match(const str *text, const str *pattern, int match_prefix, int match_substring
|
||||
*/
|
||||
#if defined(__GNUC__) && defined(WITHOUT_QUERY_FILTER)
|
||||
coap_print_status_t
|
||||
print_wellknown(coap_context_t *context, unsigned char *buf, size_t *buflen,
|
||||
coap_print_wellknown(coap_context_t *context, unsigned char *buf, size_t *buflen,
|
||||
size_t offset,
|
||||
coap_opt_t *query_filter __attribute__ ((unused))) {
|
||||
#else /* not a GCC */
|
||||
coap_print_status_t
|
||||
print_wellknown(coap_context_t *context, unsigned char *buf, size_t *buflen,
|
||||
coap_print_wellknown(coap_context_t *context, unsigned char *buf, size_t *buflen,
|
||||
size_t offset, coap_opt_t *query_filter) {
|
||||
#endif /* GCC */
|
||||
coap_resource_t *r;
|
||||
|
||||
Reference in new issue
Block a user