summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchakradhar <v.pogiri@samsung.com>2020-06-30 10:41:36 +0530
committerchakradhar <v.pogiri@samsung.com>2020-06-30 10:41:36 +0530
commit27deffd72c42d10244c2d1e6b7692919e4eddc10 (patch)
tree5ced4f931dd215255c90b39ec8f9e5baaae2ab4d
parentd02f9c5beb76f07ab71160fe9c6d295650e6eef0 (diff)
downloadlocation-manager-27deffd72c42d10244c2d1e6b7692919e4eddc10.tar.gz
location-manager-27deffd72c42d10244c2d1e6b7692919e4eddc10.tar.bz2
location-manager-27deffd72c42d10244c2d1e6b7692919e4eddc10.zip
checking argument for location_bounds_contains_coordinates_on_edge APIsubmit/tizen/20200716.061924submit/tizen/20200704.044508submit/tizen/20200701.055008
Change-Id: Ia812d95fb7ee0ea56552c267b0264d9b4c271ebe
-rw-r--r--src/location_bounds.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/location_bounds.c b/src/location_bounds.c
index 041231f..b4c0433 100644
--- a/src/location_bounds.c
+++ b/src/location_bounds.c
@@ -271,6 +271,11 @@ EXPORT_API bool location_bounds_contains_coordinates_on_edge(location_bounds_h b
return FALSE;
}
+ if (tolerance < 0.0) {
+ set_last_result(LOCATION_BOUNDS_ERROR_INVALID_PARAMETER);
+ return FALSE;
+ }
+
LocationPosition *pos = location_position_new(0, coords.latitude, coords.longitude, 0, LOCATION_STATUS_2D_FIX);
if (pos == NULL) {
//LCOV_EXCL_START