Menu

How to detect device has been shut down?

lad
2012-02-08
2014-05-13
  • lad

    lad - 2012-02-08

    Your library is very easy to use, I have completed all of the features.Thank you! ! !
    But I still have a problem that needs your help.
    If the device has been shut down, but the client has not updated in a timely manner. If you post action at this time will result in a long time without the corresponding results, this will cause the client to crash. I try to use "cg_upnp_device_isrunning (cObject)" function to detect whether the device is turned on or off . But this function always returns false. Could you please tell me how can I do?

     
  • Satoshi Konno

    Satoshi Konno - 2012-02-10

    Hi,

    cg_upnp_device_isrunning() returns false when the device is stopped using cg_upnp_device_stop().

    I think that CyberLink is crashed because some thread is running after the device is
    stopped or destroyed. I will change to handle all threads to kill the the threads
    when the device is stopped.

    Please wait for a while :-)

    Best Regards,

    Satoshi Konno

     
    • Gnash

      Gnash - 2014-05-13

      Hi Satoshi-san,

      Do you have the fix for the issue what you found, still in latest Git code i can see such crash on cg_upnp_device_stop().

       
  • lad

    lad - 2012-02-10

    I found it blocked about 20 seconds in the socket connect function, can I set the connection timeout value?Finally thank you for your reply, thank you for your  library, it is really great! Similarly, look forward to your updates.

     
  • lad

    lad - 2012-02-13

    Hi,skonno

    I found through the select function can set the socket connection timeout, the above problem has been solved, now  i set to 10 seconds , no longer have to wait so long for invalid device. Thank you for your answer.

    Bese Regards,
    ladmini

     

Log in to post a comment.