summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pcap_io.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/pcap_io.h b/pcap_io.h
index 8eb503a..5d338bb 100644
--- a/pcap_io.h
+++ b/pcap_io.h
@@ -625,7 +625,7 @@ static inline void pcap_prepare_header(struct pcap_filehdr *hdr, uint32_t magic,
hdr->magic = magic;
hdr->version_major = swapped ? ___constant_swab16(PCAP_VERSION_MAJOR) : PCAP_VERSION_MAJOR;
hdr->version_minor = swapped ? ___constant_swab16(PCAP_VERSION_MINOR) : PCAP_VERSION_MINOR;
- hdr->thiszone = swapped ? ___constant_swab32(thiszone) : thiszone;
+ hdr->thiszone = swapped ? (int32_t) ___constant_swab32(thiszone) : thiszone;
hdr->sigfigs = 0;
hdr->snaplen = swapped ? ___constant_swab32(snaplen) : snaplen;
hdr->linktype = swapped ? ___constant_swab32(linktype) : linktype;
me values it got are consistent by checking the version before and after reading them. Add CPU barries after getting version value just like what function vread_pvclock does, because all of callees in this function is inline. Fixes: 502dfeff239e8313bfbe906ca0a1a6827ac8481b Cc: stable@vger.kernel.org Signed-off-by: Minfei Huang <mnghuan@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'Documentation/devicetree/bindings/ufs')