]> rtime.felk.cvut.cz Git - pes-rpp/rpp-lwip.git/commitdiff
patch by Bostjan Meglic: fixed bug #35809: PPP GetMask(): Compiler warning on big...
authorgoldsimon <goldsimon@gmx.de>
Mon, 12 Mar 2012 15:39:52 +0000 (16:39 +0100)
committergoldsimon <goldsimon@gmx.de>
Mon, 12 Mar 2012 15:39:52 +0000 (16:39 +0100)
CHANGELOG
src/netif/ppp/ppp.c

index 8983318948fb56535ff55a2f2d3e4a129f5bb95c..940c040ef168d6a4e0ed1b7dd5b5b7a13c87aaa9 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -76,6 +76,10 @@ HISTORY
 
  ++ Bugfixes:
 
+  2012-03-12: Simon Goldschmidt (patch by Bostjan Meglic)
+  * ppp.c: fixed bug #35809: PPP GetMask(): Compiler warning on big endian,
+    possible bug on little endian system
+
   2012-02-23: Simon Goldschmidt
   * etharp.c: fixed bug #35595: Impossible to send broadcast without a gateway
     (introduced when fixing bug# 33551)
index 06d9699faade14bd890a3f0fa6e2486b975d6b69..8e8fae9f9f441a77815dcab2d89f6cbaf0287ee6 100644 (file)
@@ -1272,7 +1272,7 @@ GetMask(u32_t addr)
 {
   u32_t mask, nmask;
 
-  htonl(addr);
+  addr = htonl(addr);
   if (IP_CLASSA(addr)) { /* determine network mask for address class */
     nmask = IP_CLASSA_NET;
   } else if (IP_CLASSB(addr)) {