[OpenWrt-Devel] [PATCH] libubus.h: marking unused variables

Karl Palsson karlp at tweak.net.au
Wed Feb 10 08:24:23 EST 2016


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Isn't it more standard and cross compiler to do instead...

(void)ctx;

Rather than sprinkling gcc attributes around?

Sincerely,
Karl Palsson

Emanuel Taube <emanuel.taube at gmail.com> wrote:
> 
> diff --git a/libubus.h b/libubus.h
> index 08dac49..d419205 100644
> --- a/libubus.h
> +++ b/libubus.h
> @@ -285,7 +285,7 @@ int ubus_invoke_async(struct ubus_context *ctx, uint32_t obj, const char *method
>  int ubus_send_reply(struct ubus_context *ctx, struct ubus_request_data *req,
>  		    struct blob_attr *msg);
>  
> -static inline void ubus_defer_request(struct ubus_context
> *ctx, +static inline void ubus_defer_request(struct
> ubus_context *ctx __attribute__((__unused__)),
>  				      struct ubus_request_data *req,
>  				      struct ubus_request_data *new_req)
>  {
> @@ -293,7 +293,7 @@ static inline void ubus_defer_request(struct ubus_context *ctx,
>      req->deferred = true;
>  }
>  
> -static inline void ubus_request_set_fd(struct ubus_context
> *ctx, +static inline void ubus_request_set_fd(struct
> ubus_context *ctx __attribute__((__unused__)),
>  				       struct ubus_request_data *req, int fd)
>  {
>      req->fd = fd;
> -- 
> 2.7.0
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel at lists.openwrt.org
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

- -- 
Sent using Mailpile, Free Software from www.mailpile.is

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iQIcBAEBAgAGBQJWuzoHAAoJEBmotQ/U1cr2BiIP/0QM/1bxQ4Fr6ZJJqWWHDRIR
+92rSQdVhMXoMdYZFY2UEpzStSWbx4jcbLidptMdEdTfVAUP0ZmCTvfVBTizhB2n
U0StyUW/DAGJ7hOPHJMTZ9FB8q9xyeegtZeg5VPaXyawI/zx7i5cOmd+CItR0fi9
UqjzHRVmuSYKUrcAhE71np1MSP0OaYwYSb6yKcu2fB/V1tZJtfcJDLLiBUZaOcCy
SOCUyDJnIn8utQAfT0ZDNOdgydGyvNz5uANNWOfwD1zcKv7L1kOR3RY/Ax4IEbbR
88UJ3gsSlI+0XlEdNHfWxoVwx6Y385AUMkULEu+Rg7RFUvXkixfFO0TvhHqXtlzL
dWziwRbGPyIxbzwHxzGfJMQwS87HsbIc7JcsyJ1aEkT1vDFDeMR8aREVYLx48ex+
FoZgB8Dh3XhCo4Q1ojGtvHjGRWXSHXnDKzf0tr6Thiq8TUINyt6QX3iUWsbKq1KJ
mhvsvkQRluKVjDCRbhQFnAlou2iosoKMb8W7C0hrOt/9LMGoJYruPNj2omXWrTNJ
EYCmiTl4dCcnsQfMFgR3H4S+3X+DuitHtJ0tADH6b5cgkuQ2DXvJxQT0/t+ccW7H
F2wW6U+sj95n9CeM0Rt5RNqvLXh2n9IvMQhH5WikdUYRXrinMspopsDRoZPzvyWD
G+5hm49Zrpl4ayuKjYxS
=RtlU
-----END PGP SIGNATURE-----
-------------- next part --------------
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list