ping (cont)
Till Straumann
strauman at SLAC.Stanford.EDU
Mon Apr 14 18:59:09 UTC 2003
Charles Steaderman wrote:
> Just a quick update and another few questions.
>
> 1) I was able to get ping.c from OpenBSD integrated with a wrapper
> function (similar to the ttcp implementation). Unfortunately, ping does
> NOT clean up after itself. It allocates a buffer for the packet data
> which is never free'd and it never closes its socket handle. Apparently
> it relies upon the operating system to cleanup when the program exits.
> Aarg. If the ping_main() function were wrapped into an RTEMS task which
> deleted itself when complete, would the allocated memory and socked
> handle be returned?
no. Pretty much all RTEMS resources are global and their state does
not change when a thread is deleted.
> For now I hacked the ping.c source and perform the
> cleanup.
>
You probably could use a 'task deletion user extension' if you don't
want to modify the source at all.
> 2) I am still trying to figure out how to handle signal notification.
> When a signal timer expires, how do I get the current function pointer
> associated with the particular signal?
Sorry, "help not available"
-- Till
>
> Any direction, especially for question 2 would be greatly appreciated.
>
> - Charlie
>
More information about the users
mailing list