[Release version 0.2.41] Fix UTC - invalid parameter check 57/58157/1 accepted/tizen/mobile/20160128.050804 accepted/tizen/tv/20160128.050828 accepted/tizen/wearable/20160128.050853 submit/tizen/20160128.031600
authorJeongmo Yang <jm80.yang@samsung.com>
Thu, 28 Jan 2016 03:10:51 +0000 (12:10 +0900)
committerJeongmo Yang <jm80.yang@samsung.com>
Thu, 28 Jan 2016 03:10:51 +0000 (12:10 +0900)
Change-Id: I03937f3d024d2034c287fe3345ba2d81da9c5e3f
Signed-off-by: Jeongmo Yang <jm80.yang@samsung.com>
packaging/capi-media-camera.spec
src/camera.c

index a780c72..4bb930e 100644 (file)
@@ -3,7 +3,7 @@
 
 Name:       capi-media-camera
 Summary:    A Camera API
-Version:    0.2.40
+Version:    0.2.41
 Release:    0
 Group:      Multimedia/API
 License:    Apache-2.0
index b073f9d..740df79 100644 (file)
@@ -2647,6 +2647,10 @@ int camera_set_display_rotation(camera_h camera, camera_rotation_e rotation)
                return CAMERA_ERROR_INVALID_PARAMETER;
        }
 
+       if (rotation < CAMERA_ROTATION_NONE || rotation > CAMERA_ROTATION_270) {
+               return CAMERA_ERROR_INVALID_PARAMETER;
+       }
+
        pc = (camera_cli_s *)camera;
 
        if (pc->client_handle == NULL) {
@@ -2695,6 +2699,10 @@ int camera_set_display_flip(camera_h camera, camera_flip_e flip)
                return CAMERA_ERROR_INVALID_PARAMETER;
        }
 
+       if (flip < CAMERA_FLIP_NONE || flip > CAMERA_FLIP_BOTH) {
+               return CAMERA_ERROR_INVALID_PARAMETER;
+       }
+
        pc = (camera_cli_s *)camera;
 
        if (pc->client_handle == NULL) {
@@ -2797,6 +2805,10 @@ int camera_set_display_mode(camera_h camera, camera_display_mode_e mode)
                return CAMERA_ERROR_INVALID_PARAMETER;
        }
 
+       if (mode < CAMERA_DISPLAY_MODE_LETTER_BOX || mode > CAMERA_DISPLAY_MODE_CROPPED_FULL) {
+               return CAMERA_ERROR_INVALID_PARAMETER;
+       }
+
        pc = (camera_cli_s *)camera;
 
        if (pc->client_handle == NULL) {