* [U-Boot] [PATCH] net: add random_port() prototype
@ 2009-09-02 8:18 Mike Frysinger
2009-09-10 23:00 ` Ben Warren
0 siblings, 1 reply; 2+ messages in thread
From: Mike Frysinger @ 2009-09-02 8:18 UTC (permalink / raw)
To: u-boot
The random_port() is meant to be used by other net code, but without a
prototype, we get fun warnings like:
dns.c: In function 'DnsSend':
dns.c:89: warning: implicit declaration of function 'random_port'
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
include/net.h | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/include/net.h b/include/net.h
index 4873000..1c8ab12 100644
--- a/include/net.h
+++ b/include/net.h
@@ -517,6 +517,9 @@ extern ushort getenv_VLAN(char *);
/* copy a filename (allow for "..." notation, limit length) */
extern void copy_filename (char *dst, char *src, int size);
+/* get a random source port */
+extern unsigned int random_port(void);
+
/**********************************************************************/
#endif /* __NET_H__ */
--
1.6.4.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [U-Boot] [PATCH] net: add random_port() prototype
2009-09-02 8:18 [U-Boot] [PATCH] net: add random_port() prototype Mike Frysinger
@ 2009-09-10 23:00 ` Ben Warren
0 siblings, 0 replies; 2+ messages in thread
From: Ben Warren @ 2009-09-10 23:00 UTC (permalink / raw)
To: u-boot
Mike Frysinger wrote:
> The random_port() is meant to be used by other net code, but without a
> prototype, we get fun warnings like:
> dns.c: In function 'DnsSend':
> dns.c:89: warning: implicit declaration of function 'random_port'
>
> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
> ---
> include/net.h | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/include/net.h b/include/net.h
> index 4873000..1c8ab12 100644
> --- a/include/net.h
> +++ b/include/net.h
> @@ -517,6 +517,9 @@ extern ushort getenv_VLAN(char *);
> /* copy a filename (allow for "..." notation, limit length) */
> extern void copy_filename (char *dst, char *src, int size);
>
> +/* get a random source port */
> +extern unsigned int random_port(void);
> +
> /**********************************************************************/
>
> #endif /* __NET_H__ */
>
Applied to net repo.
thanks,
Ben
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-09-10 23:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-02 8:18 [U-Boot] [PATCH] net: add random_port() prototype Mike Frysinger
2009-09-10 23:00 ` Ben Warren
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox