From: Deokhyun Kim Date: Wed, 5 Jul 2017 02:05:36 +0000 (+0900) Subject: Fix SVace issue. X-Git-Tag: submit/tizen_3.0/20170716.235230^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d7d2040c776c46a7d9bdc3419b53ada9c000dc92;p=platform%2Fcore%2Fapi%2Fbluetooth.git Fix SVace issue. Change-Id: I625793c394c093c37ec6ab9c9b8ade2af85369b3 Signed-off-by: Deokhyun Kim --- diff --git a/src/bluetooth-tds.c b/src/bluetooth-tds.c index ab3c275..5a9a7e6 100644 --- a/src/bluetooth-tds.c +++ b/src/bluetooth-tds.c @@ -239,7 +239,7 @@ int bt_tds_provider_set_transport_data(bt_tds_provider_h provider, if (!tds_provider_registered) return BT_ERROR_NOT_INITIALIZED; - if (255 < length) { + if (0 >= length || BLUETOOTH_TDS_DATA_LENGTH_MAX < length) { error_code = BT_ERROR_INVALID_PARAMETER; BT_ERR("%s(0x%08x)", _bt_convert_error_to_string(error_code), error_code); return error_code;