use rtapi_print_msg() instead of cerr
use rtapi_print_msg() instead of cerr

when waiting for the master, delay a variable amount of time.  this way,
if two rtapi_apps are started at the same time and a socket from a dead
rtapi_app is still around, the chance that both of them decide to convert
to master is decreased. (there's probably a race-free way to do this, but
I haven't found what it is)

unseenlaser/linuxcnc,RunningLight/machinekit,mhaberler/machinekit,RunningLight/machinekit,mhaberler/machinekit,Cid427/machinekit,EqAfrica/machinekit,ikcalB/linuxcnc-mirror,bobvanderlinden/machinekit,kinsamanka/machinekit,yishinli/emc2,EqAfrica/machinekit,cdsteinkuehler/linuxcnc,ikcalB/linuxcnc-mirror,araisrobo/linuxcnc,kinsamanka/machinekit,EqAfrica/machinekit,unseenlaser/machinekit,ianmcmahon/linuxcnc-mirror,bmwiedemann/linuxcnc-mirror,araisrobo/machinekit,ArcEye/machinekit-testing,bobvanderlinden/machinekit,mhaberler/machinekit,unseenlaser/linuxcnc,ArcEye/MK-Qt5,bobvanderlinden/machinekit,bobvanderlinden/machinekit,unseenlaser/machinekit,strahlex/machinekit,strahlex/machinekit,cnc-club/linuxcnc,ArcEye/MK-Qt5,araisrobo/machinekit,ArcEye/machinekit-testing,cnc-club/linuxcnc,strahlex/machinekit,cdsteinkuehler/MachineKit,araisrobo/machinekit,cdsteinkuehler/MachineKit,aschiffler/linuxcnc,RunningLight/machinekit,RunningLight/machinekit,araisrobo/machinekit,RunningLight/machinekit,ianmcmahon/linuxcnc-mirror,ArcEye/machinekit-testing,unseenlaser/linuxcnc,ArcEye/MK-Qt5,araisrobo/linuxcnc,ianmcmahon/linuxcnc-mirror,bobvanderlinden/machinekit,jaguarcat79/ILC-with-LinuxCNC,araisrobo/linuxcnc,araisrobo/linuxcnc,cdsteinkuehler/linuxcnc,EqAfrica/machinekit,araisrobo/machinekit,RunningLight/machinekit,ArcEye/MK-Qt5,bobvanderlinden/machinekit,aschiffler/linuxcnc,ikcalB/linuxcnc-mirror,unseenlaser/linuxcnc,unseenlaser/machinekit,ikcalB/linuxcnc-mirror,cdsteinkuehler/MachineKit,ikcalB/linuxcnc-mirror,araisrobo/machinekit,yishinli/emc2,narogon/linuxcnc,narogon/linuxcnc,ianmcmahon/linuxcnc-mirror,unseenlaser/machinekit,Cid427/machinekit,ikcalB/linuxcnc-mirror,Cid427/machinekit,cnc-club/linuxcnc,ianmcmahon/linuxcnc-mirror,jaguarcat79/ILC-with-LinuxCNC,EqAfrica/machinekit,cdsteinkuehler/linuxcnc,unseenlaser/linuxcnc,narogon/linuxcnc,EqAfrica/machinekit,unseenlaser/machinekit,ianmcmahon/linuxcnc-mirror,ArcEye/machinekit-testing,cdsteinkuehler/MachineKit,jaguarcat79/ILC-with-LinuxCNC,RunningLight/machinekit,kinsamanka/machinekit,cdsteinkuehler/linuxcnc,strahlex/machinekit,Cid427/machinekit,cdsteinkuehler/MachineKit,EqAfrica/machinekit,cdsteinkuehler/linuxcnc,Cid427/machinekit,cnc-club/linuxcnc,bmwiedemann/linuxcnc-mirror,ArcEye/MK-Qt5,ikcalB/linuxcnc-mirror,kinsamanka/machinekit,mhaberler/machinekit,cnc-club/linuxcnc,strahlex/machinekit,bmwiedemann/linuxcnc-mirror,ArcEye/machinekit-testing,ArcEye/machinekit-testing,ArcEye/MK-Qt5,araisrobo/machinekit,bmwiedemann/linuxcnc-mirror,mhaberler/machinekit,kinsamanka/machinekit,araisrobo/machinekit,aschiffler/linuxcnc,yishinli/emc2,kinsamanka/machinekit,RunningLight/machinekit,narogon/linuxcnc,Cid427/machinekit,unseenlaser/machinekit,Cid427/machinekit,cnc-club/linuxcnc,bobvanderlinden/machinekit,cdsteinkuehler/MachineKit,araisrobo/linuxcnc,bobvanderlinden/machinekit,aschiffler/linuxcnc,bmwiedemann/linuxcnc-mirror,jaguarcat79/ILC-with-LinuxCNC,araisrobo/machinekit,ArcEye/MK-Qt5,cdsteinkuehler/linuxcnc,aschiffler/linuxcnc,bmwiedemann/linuxcnc-mirror,narogon/linuxcnc,Cid427/machinekit,ArcEye/MK-Qt5,EqAfrica/machinekit,ianmcmahon/linuxcnc-mirror,yishinli/emc2,mhaberler/machinekit,unseenlaser/machinekit,jaguarcat79/ILC-with-LinuxCNC,mhaberler/machinekit,bmwiedemann/linuxcnc-mirror,strahlex/machinekit,kinsamanka/machinekit,strahlex/machinekit,unseenlaser/machinekit,ArcEye/machinekit-testing,ArcEye/machinekit-testing,kinsamanka/machinekit,cnc-club/linuxcnc,mhaberler/machinekit