[Release] wrt-installer_0.1.39
[framework/web/wrt-installer.git] / src / jobs / widget_install / task_install_ospsvc.cpp
index 3fe94ef..7909c26 100644 (file)
@@ -69,7 +69,15 @@ void TaskInstallOspsvc::StepInstallOspService()
                  "Error occurs during\
                 install osp service");
     }
-    fgets(readBuf, MAX_BUF_SIZE, fd);
+
+    if (fgets(readBuf, MAX_BUF_SIZE, fd) == NULL)
+    {
+        LogError("Failed to installtion osp service.\
+                Inability of reading file.");
+        ThrowMsg(Exceptions::InstallOspsvcFailed,
+                "Error occurs during\
+                install osp service");
+    }
     LogDebug("return value : " << readBuf);
 
     int result = atoi(readBuf);