original_kernel/net/dccp
Gerrit Renker 24c667db59 [CCID2/3]: Initialisation assignments of 0 are redundant
Assigning initial values of `0' is redundant when loading a new CCID structure,
since in net/dccp/ccid.c the entire CCID structure is zeroed out prior to
initialisation in ccid_new():

    	struct ccid {
    		struct ccid_operations *ccid_ops;
    		char		       ccid_priv[0];
    	};

    	// ...
    	if (rx) {
    		memset(ccid + 1, 0, ccid_ops->ccid_hc_rx_obj_size);
    		if (ccid->ccid_ops->ccid_hc_rx_init != NULL &&
    		    ccid->ccid_ops->ccid_hc_rx_init(ccid, sk) != 0)
    			goto out_free_ccid;
    	} else {
    		memset(ccid + 1, 0, ccid_ops->ccid_hc_tx_obj_size);
    		/* analogous to the rx case */
    	}

This patch therefore removes the redundant assignments. Thanks to Arnaldo for
the inspiration.

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Signed-off-by: Ian McDonald <ian.mcdonald@jandi.co.nz>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2007-10-24 10:53:01 -02:00
..
ccids [CCID2/3]: Initialisation assignments of 0 are redundant 2007-10-24 10:53:01 -02:00
Kconfig
Makefile
ackvec.c
ackvec.h
ccid.c
ccid.h
dccp.h
diag.c
feat.c
feat.h
input.c [DCCP]: Convert Reset code into socket error number 2007-10-24 10:27:48 -02:00
ipv4.c [DCCP]: One more exemption from full sequence number checks 2007-10-24 10:18:06 -02:00
ipv6.c [DCCP]: Retrieve packet sequence number for error reporting 2007-10-24 10:12:09 -02:00
ipv6.h
minisocks.c
options.c [DCCP]: Unaligned pointer access 2007-10-24 10:46:58 -02:00
output.c
probe.c
proto.c [DCCP]: Implement SIOCINQ/FIONREAD 2007-10-23 21:27:50 -07:00
sysctl.c
timer.c