Fixed segmentation fault when device added.
Fixed segmentation fault when device added.

nitroshare/nitroshare-desktop,arno01/nitroshare-desktop,nitroshare/nitroshare-desktop,nitroshare/nitroshare-desktop,nitroshare/nitroshare-desktop