Am 29.12.2016 um 17:52 schrieb Christian Grothoff: > Ideally, your application should pick such a hash-port at random or > based on a shared secret of the various participants. In the rare cases > where you do need to hard code one, just use a string describing the > purpose and hash that.
For CADET port numbers I can do the port selection in the described way. However, what's about the GNUNET message types? >> 2) GNUNET_PROGRAM_run() does not terminates, if services (i.e. ARM) are >> not running. Is this behavior intended? (Workaround: should I use exit >> in shutdown task?) > > GNUNET_PROGRAM_run() will only terminate once all activities of your > process have terminated. Usually, the issue behind such non-termination > is that you need to install a shutdown task and use it to explicitly > stop ongoing actions. This is exactly what I did. I implemented a shutdown task (registered with GNUNET_SCHEDULER_add_shutdown) which is called in case of errors and e.g. by interrupting the main loop through SIGTERM. When GNUNET services are running, everything terminates fine. Otherwise the control also left this shutdown task but the calling GNUNET_PROGRAM_run() does not terminates while trying to connect to ARM service. As a workaround I can call exit(GNUNET_OK) in the shutdown task, but I guess this is not intended? Bests, Heiko. _______________________________________________ GNUnet-developers mailing list [email protected] https://lists.gnu.org/mailman/listinfo/gnunet-developers
