Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/dist/iscsi/src Use the ISCSI_NTOHL macro in place of a strai...



details:   https://anonhg.NetBSD.org/src/rev/e66b173cbbe1
branches:  trunk
changeset: 588139:e66b173cbbe1
user:      agc <agc%NetBSD.org@localhost>
date:      Thu Feb 09 08:55:00 2006 +0000

description:
Use the ISCSI_NTOHL macro in place of a straight ntohl(), so that this
can be abstracted away per platform.

diffstat:

 dist/iscsi/src/target.c |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 29c0e2451ece -r e66b173cbbe1 dist/iscsi/src/target.c
--- a/dist/iscsi/src/target.c   Thu Feb 09 08:46:43 2006 +0000
+++ b/dist/iscsi/src/target.c   Thu Feb 09 08:55:00 2006 +0000
@@ -217,7 +217,7 @@
                                scsi_cmd.ext_cdb = ahs_ptr + 4;
                                break;
                        case 0x02:
-                               scsi_cmd.bidi_trans_len = ntohl(*((uint32_t *) (void *) (ahs_ptr + 4)));
+                               scsi_cmd.bidi_trans_len = ISCSI_NTOHL(*((uint32_t *) (void *) (ahs_ptr + 4)));
                                *((uint32_t *) (void *) (ahs_ptr + 4)) = scsi_cmd.bidi_trans_len;
                                TRACE(TRACE_ISCSI_DEBUG, "Got Bidirectional Read AHS (expected read length %u)\n", scsi_cmd.bidi_trans_len);
                                break;



Home | Main Index | Thread Index | Old Index