[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 15/19] device/net_io.c: quiet the warning about uninitialized
From: |
Samuel Thibault |
Subject: |
Re: [PATCH 15/19] device/net_io.c: quiet the warning about uninitialized variable |
Date: |
Wed, 20 Nov 2013 21:54:42 +0100 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Marin Ramesa, le Wed 20 Nov 2013 13:53:57 +0100, a écrit :
> * device/net_io.c (hash_entp): Initialize.
It doesn't seem so clear that it's actually always properly initialized.
We also need a comment explaining why it always is.
> ---
> device/net_io.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/device/net_io.c b/device/net_io.c
> index 1958840..857fc89 100644
> --- a/device/net_io.c
> +++ b/device/net_io.c
> @@ -1158,7 +1158,7 @@ net_set_filter(ifp, rcv_port, priority, filter,
> filter_count)
> net_rcv_port_t infp, my_infp;
> net_rcv_port_t nextfp;
> net_hash_header_t hhp;
> - net_hash_entry_t entp, hash_entp;
> + net_hash_entry_t entp, hash_entp = hash_entp;
> net_hash_entry_t *head, nextentp;
> queue_entry_t dead_infp, dead_entp;
> int i;
> --
> 1.8.1.4
>
>
--
Samuel
CN > J'ai enseigné l'algorythmique.
GLG> C'est quoi l'algorythmique ? Une contrebasse programmée en Algol ?
-+- in : Guide du Neuneu d'Usenet - Neuneu fait ses gammes. -+-
- Re: [PATCH 09/19] ddb/db_run.c: move declaration of brpc into SOFTWARE_SSTEP, (continued)
[PATCH 10/19] ddb/db_sym.c: add parentheses around assignment used as truth value, Marin Ramesa, 2013/11/20
[PATCH 11/19] ddb/db_variables.c: fix initializations from incompatible pointer type, Marin Ramesa, 2013/11/20
[PATCH 12/19] ipc/ipc_print.h: include ipc/ipc_pset.h for ipc_pset_t, Marin Ramesa, 2013/11/20
[PATCH 13/19] kern/startup.c: fix implicit declaration of function, Marin Ramesa, 2013/11/20
[PATCH 14/19] kern/xpr.c: quiet warning about uninitialized variable, Marin Ramesa, 2013/11/20
[PATCH 15/19] device/net_io.c: quiet the warning about uninitialized variable, Marin Ramesa, 2013/11/20
- Re: [PATCH 15/19] device/net_io.c: quiet the warning about uninitialized variable,
Samuel Thibault <=
[PATCH 16/19] Fix implicit declaration of function, Marin Ramesa, 2013/11/20
[PATCH 17/19] i386/i386at/kd.c: add forward declaration, Marin Ramesa, 2013/11/20
[PATCH 18/19] i386/i386/db_interface.c: add forward declaration, Marin Ramesa, 2013/11/20
[PATCH 19/19] i386/i386/db_interface.c: fix implicit declaration of function, Marin Ramesa, 2013/11/20