Fixed module path. 54/42654/3 tizen_3.0.m1_tv accepted/tizen/mobile/20150702.004655 accepted/tizen/tv/20150702.004719 accepted/tizen/wearable/20150702.004736 submit/tizen/20150701.130745 submit/tizen_common/20151015.190624 submit/tizen_common/20151019.135620 submit/tizen_common/20151023.083358 submit/tizen_common/20151026.085049 submit/tizen_mobile/20150701.130630 submit/tizen_wearable/20150701.130648 tizen_3.0.m1_tv_release
authorYoung-Ae Kang <youngae.kang@samsung.com>
Wed, 1 Jul 2015 08:19:05 +0000 (17:19 +0900)
committerkj7.sung <kj7.sung@samsung.com>
Wed, 1 Jul 2015 10:38:16 +0000 (19:38 +0900)
Signed-off-by: Young-Ae Kang <youngae.kang@samsung.com>
Change-Id: I9cb0284cccf09e068449300033127f3bc72304f4

location/manager/location-hybrid-mobile.c
location/module/module-internal.c
packaging/liblbs-location.spec

index 4495283..0c4c5d2 100644 (file)
@@ -337,7 +337,7 @@ hybrid_service_updated(GObject *obj,
                        LOCATION_LOGD("Searching GPS");
 
                        /* restart WPS when GPS not available */
-                       g_object_get(priv->wps, "is_started", &wps_started, NULL);
+                       if (priv->wps) g_object_get(priv->wps, "is_started", &wps_started, NULL);
                        if (priv->wps && wps_started == FALSE) {
                                ret = location_start(priv->wps);
                                if (ret != LOCATION_ERROR_NONE) {
@@ -378,7 +378,7 @@ hybrid_service_updated(GObject *obj,
                }
 
                /* if receive GPS position then stop WPS.. */
-               g_object_get(priv->wps, "is_started", &wps_started, NULL);
+               if (priv->wps) g_object_get(priv->wps, "is_started", &wps_started, NULL);
                if (LOCATION_TYPE_GPS == g_type && wps_started == TRUE) {
                        ret = location_stop(priv->wps);
                        if (ret != LOCATION_ERROR_NONE) {
@@ -449,9 +449,13 @@ location_hybrid_start(LocationHybrid *self)
 
        LocationHybridPrivate *priv = GET_PRIVATE(self);
        g_return_val_if_fail(priv, LOCATION_ERROR_NOT_AVAILABLE);
+       if (!priv->gps && !priv->wps) {
+               LOCATION_LOGE("GPS and WPS Object are not created.");
+               return LOCATION_ERROR_NOT_AVAILABLE;
+       }
 
-       g_object_get(priv->gps, "is_started", &gps_started, NULL);
-       g_object_get(priv->wps, "is_started", &wps_started, NULL);
+       if (priv->gps) g_object_get(priv->gps, "is_started", &gps_started, NULL);
+       if (priv->wps) g_object_get(priv->wps, "is_started", &wps_started, NULL);
 
        if ((gps_started == TRUE) || (wps_started == TRUE)) {
                LOCATION_LOGD("Already started");
@@ -508,7 +512,7 @@ location_hybrid_stop(LocationHybrid *self)
        gboolean wps_started = FALSE;
 
        g_object_get(priv->gps, "is_started", &gps_started, NULL);
-       g_object_get(priv->wps, "is_started", &wps_started, NULL);
+       if (priv->wps) g_object_get(priv->wps, "is_started", &wps_started, NULL);
 
        if ((gps_started == FALSE) && (wps_started == FALSE)) {
                return LOCATION_ERROR_NONE;
index 15c3e4c..7e4a292 100644 (file)
 #include "location-log.h"
 
 #define MAX_MODULE_INDEX 4
-#ifdef LOG_TAG
-#undef LOG_TAG
-#define LOG_TAG TAG_LOCATION_FWK
-#endif
 
-#define MODULE_PATH_PREFIX LIBDIR"location/module"
+#define MODULE_PATH_PREFIX LIBDIR"/location/module"
 /* const char *MODULE_PATH_PREFIX = "/usr/lib/location/module"; */
 
 static GMod *gmod_new(const char *module_name, gboolean is_resident)
index 443c55e..b7312c9 100755 (executable)
@@ -51,7 +51,7 @@ MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
 #cmake . -DCMAKE_INSTALL_PREFIX=/usr -DFULLVER=%{version} -DMAJORVER=${MAJORVER} \
 cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DBUILD_PKGTYPE=rpm -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
 -DFULLVER=%{version} -DMAJORVER=${MAJORVER} \
-%if "%{?tizen_profile_name}" == "wearable"
+%if "%{profile}" == "wearable"
        -DFEATURE_PROFILE_WEARABLE:BOOL=ON
 %else
        -DFEATURE_PROFILE_WEARABLE:BOOL=OFF