Commit 78332e330cd0f7644ce43fbd1508cee181db0f8e
1 parent
981631c3
Exists in
master
and in
5 other branches
Leitura de tela via hllapi estava deslocada.
Showing
1 changed file
with
7 additions
and
0 deletions
Show diff stats
src/plugins/hllapi/calls.cc
@@ -278,6 +278,13 @@ | @@ -278,6 +278,13 @@ | ||
278 | { | 278 | { |
279 | int rc = HLLAPI_STATUS_SYSTEM_ERROR; | 279 | int rc = HLLAPI_STATUS_SYSTEM_ERROR; |
280 | 280 | ||
281 | + if(offset < 1) | ||
282 | + { | ||
283 | + return HLLAPI_STATUS_BAD_PARAMETER; | ||
284 | + } | ||
285 | + | ||
286 | + offset--; | ||
287 | + | ||
281 | if(!session::has_default()) | 288 | if(!session::has_default()) |
282 | { | 289 | { |
283 | return HLLAPI_STATUS_DISCONNECTED; | 290 | return HLLAPI_STATUS_DISCONNECTED; |