Skip to content

Commit

Permalink
libceph: directly skip to the end of redirect reply
Browse files Browse the repository at this point in the history
Coverity complains about a double write to *p.  Don't bother with
osd_instructions and directly skip to the end of redirect reply.

Reported-by: Colin Ian King <[email protected]>
Signed-off-by: Ilya Dryomov <[email protected]>
  • Loading branch information
idryomov committed Mar 30, 2020
1 parent 4d8b8fb commit bb0e681
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions net/ceph/osd_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -3483,9 +3483,6 @@ static int ceph_redirect_decode(void **p, void *end,
goto e_inval;
}

len = ceph_decode_32(p);
*p += len; /* skip osd_instructions */

/* skip the rest */
*p = struct_end;
out:
Expand Down

0 comments on commit bb0e681

Please sign in to comment.