lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [bug #49827] wrong cast to size_t on 16-bit x86 architectur


From: Alexander
Subject: [lwip-devel] [bug #49827] wrong cast to size_t on 16-bit x86 architecture
Date: Mon, 12 Dec 2016 08:10:56 +0000 (UTC)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.99 Safari/537.36

URL:
  <http://savannah.nongnu.org/bugs/?49827>

                 Summary: wrong cast to size_t on 16-bit x86 architecture
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: pronkin
            Submitted on: Mon 12 Dec 2016 08:10:55 AM GMT
                Category: Platform ports
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: None
            lwIP version: 2.0.0

    _______________________________________________________

Details:

I work on DOS-like 16-bit OS and recently updated lwip from 1.4.1 to 2.0.0.
and found that in timouts.c:182
(http://git.savannah.gnu.org/cgit/lwip.git/tree/src/core/timeouts.c#n182)

sys_timeout(lwip_cyclic_timers[i].interval_ms, cyclic_timer,
(void*)(size_t)&lwip_cyclic_timers[i]);

unnecessary cast to size_t (before cast to void *) results wrong pointer value
in real mode x86 applications.





    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?49827>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]