This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug ada/17960] GNAT.Sockets Stream feature not working properly


------- Additional Comments From laurent at guerby dot net  2004-11-25 21:09 -------
I thought about it after having posted my comment. GNAT does not do stack
checking by default see "Stack Overflow Checking" in gcc/ada/gnat_ug.texi. Even
that is not guaranteed to work on the main thread stack IIRC.

As a general programming note, if you're reading from a socket, you either have
to be sure that you will never get garbage from it, or to seriously validate
everything you get, that of course precludes the use of 'Input and the like.

(Even if GNAT properly raises an exception, it might do so after the machine has
been swapping and unusable for a long time and most processes have been killed
by the OS, so that's really not a way to do network programming in these days of
malwares :).

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17960


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]