Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dlm: Improve a size determination in table_seq_start()

Replace the specification of a data structure by a pointer dereference
as the parameter for the operator "sizeof" to make the corresponding size
determination a bit safer according to the Linux coding style convention.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: David Teigland <teigland@redhat.com>

authored by

Markus Elfring and committed by
David Teigland
2c257e96 41922ce8

+1 -1
+1 -1
fs/dlm/debug_fs.c
··· 435 435 if (bucket >= ls->ls_rsbtbl_size) 436 436 return NULL; 437 437 438 - ri = kzalloc(sizeof(struct rsbtbl_iter), GFP_NOFS); 438 + ri = kzalloc(sizeof(*ri), GFP_NOFS); 439 439 if (!ri) 440 440 return NULL; 441 441 if (n == 0)