lwip-users
[Top][All Lists]
Advanced

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

RE : [lwip-users] Sockets.c initialize


From: Frédéric BERNON
Subject: RE : [lwip-users] Sockets.c initialize
Date: Tue, 12 Sep 2006 17:14:21 +0200

Isn't it "compiler-dependant" ?

 
  
====================================
Frédéric BERNON 
HYMATOM SA 
Chef de projet informatique 
Microsoft Certified Professional 
Tél. : +33 (0)4-67-87-61-10 
Fax. : +33 (0)4-67-70-85-44 
Email : address@hidden 
Web Site : http://www.hymatom.fr 
====================================


-----Message d'origine-----
De : address@hidden [mailto:address@hidden De la part de Krueger, Don
Envoyé : mardi 12 septembre 2006 17:05
À : Mailing list for lwIP users
Objet : RE: [lwip-users] Sockets.c initialize


 
Frédéric BERNON writes:

> Hi Group,
>
> Isn't it necessary to add in sockets.c a line like :
>
> memset( sockets, 0, sizeof(sockets));
>
> Because the "sockets" array doesn't seems to be initialized,
> and it can cause a problem to alloc_socket(...) when we look 
> for an free entry in this table. The declaration is :
>
> static struct lwip_socket sockets[NUM_SOCKETS];

No, it's not needed. The object should already be initialized. See comp.lang.c 
FAQ (1.30): http://c-faq.com/decl/initval.html


Don Krueger

====================================================================== 
 This electronic message transmission and any attachments are 
 confidential and/or proprietary and may constitute legally privileged 
information of 
 Meso Scale Diagnostics, LLC. The information is intended for solely 
 the use of Mailing list for lwIP users (address@hidden).  If you are not 
 the intended recipient, you are hereby notified that any 
 disclosure, copying, distribution or the taking of any action in 
 reliance of this information is strictly prohibited. You are not 
 authorized to retain it in any form nor to re-transmit it, and 
 you should destroy this email immediately. 

 If you have received this electronic transmission in error, 
 please notify us by telephone (240-631-2522) or by electronic 
 mail to the sender of this email, Krueger, Don (address@hidden),  immediately. 
 ===================================================================== 




_______________________________________________
lwip-users mailing list
address@hidden http://lists.nongnu.org/mailman/listinfo/lwip-users




reply via email to

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