File: 30_pntohl_shift.patch

package info (click to toggle)
dsniff 2.4b1%2Bdebian-35
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,096 kB
  • sloc: ansic: 10,803; sh: 152; makefile: 127
file content (19 lines) | stat: -rw-r--r-- 747 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Description: Corrects the incorrect bit-shift in pntohl(), the left-shift should be 8 bits, not 18.
Author: Matthew Boyle <mlb@decisionsoft.co.uk>
Origin: http://pkgs.fedoraproject.org/cgit/rpms/dsniff.git/tree/dsniff-2.4-pntohl_shift.patch
Bug-RedHat: https://bugzilla.redhat.com/show_bug.cgi?id=714958
Bug-RedHat: https://bugzilla.redhat.com/show_bug.cgi?id=850496
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/

--- a/decode.h
+++ b/decode.h
@@ -35,7 +35,7 @@
 			  (u_short)*((u_char *)p+0)<<8))
 			 
 #define pntohl(p)	((u_int32_t)*((u_char *)p+3)<<0|   \
-			 (u_int32_t)*((u_char *)p+2)<<18|  \
+			 (u_int32_t)*((u_char *)p+2)<<8|  \
 			 (u_int32_t)*((u_char *)p+1)<<16|  \
 			 (u_int32_t)*((u_char *)p+0)<<24)