diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2008-01-25 00:58:46 -0500 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2008-02-04 02:22:42 -0500 |
commit | eef7d739c218cb2546cf95686db77de0d76e4122 (patch) | |
tree | 4d6c0e65e8aff1afb2c6428c729a98274ccb1a6d /fs/dlm/dlm_internal.h | |
parent | 8b0d8e03f847d9c1677b8a193cd124debbc54633 (diff) |
dlm: dlm_process_incoming_buffer() fixes
* check that length is large enough to cover the non-variable part of message or
rcom resp. (after checking that it's large enough to cover the header, of
course).
* kill more pointless casts
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm/dlm_internal.h')
-rw-r--r-- | fs/dlm/dlm_internal.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/dlm/dlm_internal.h b/fs/dlm/dlm_internal.h index ec61bbaf25df..65499ceaa516 100644 --- a/fs/dlm/dlm_internal.h +++ b/fs/dlm/dlm_internal.h | |||
@@ -403,6 +403,12 @@ struct dlm_rcom { | |||
403 | char rc_buf[0]; | 403 | char rc_buf[0]; |
404 | }; | 404 | }; |
405 | 405 | ||
406 | union dlm_packet { | ||
407 | struct dlm_header header; /* common to other two */ | ||
408 | struct dlm_message message; | ||
409 | struct dlm_rcom rcom; | ||
410 | }; | ||
411 | |||
406 | struct rcom_config { | 412 | struct rcom_config { |
407 | uint32_t rf_lvblen; | 413 | uint32_t rf_lvblen; |
408 | uint32_t rf_lsflags; | 414 | uint32_t rf_lsflags; |