mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-06 01:45:11 +00:00
Merged revisions 238583 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r238583 | jpeeler | 2010-01-08 11:18:41 -0600 (Fri, 08 Jan 2010) | 5 lines Stop trying to find a parking space after traversing the parkinglot one time. (closes issue #16428) Reported by: Yasuhiro Konishi ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@238585 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -566,7 +566,7 @@ static struct parkeduser *park_space_reserve(struct ast_channel *chan,
|
|||||||
for (i = start; 1; i++) {
|
for (i = start; 1; i++) {
|
||||||
if (i == parkinglot->parking_stop + 1) {
|
if (i == parkinglot->parking_stop + 1) {
|
||||||
i = parkinglot->parking_start - 1;
|
i = parkinglot->parking_start - 1;
|
||||||
continue;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
AST_LIST_TRAVERSE(&parkinglot->parkings, cur, list) {
|
AST_LIST_TRAVERSE(&parkinglot->parkings, cur, list) {
|
||||||
@@ -574,8 +574,7 @@ static struct parkeduser *park_space_reserve(struct ast_channel *chan,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (!cur) {
|
||||||
if (!cur || i == start - 1) {
|
|
||||||
parking_space = i;
|
parking_space = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user