]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 277945 via svnmerge from
authorJean Galarneau <jgalarneau@digium.com>
Mon, 19 Jul 2010 21:21:20 +0000 (21:21 +0000)
committerJean Galarneau <jgalarneau@digium.com>
Mon, 19 Jul 2010 21:21:20 +0000 (21:21 +0000)
https://origsvn.digium.com/svn/asterisk/trunk

................
  r277945 | jeang | 2010-07-19 16:07:08 -0500 (Mon, 19 Jul 2010) | 15 lines

  Merged revisions 277906 via svnmerge from
  https://origsvn.digium.com/svn/asterisk/branches/1.4

  ........
    r277906 | jeang | 2010-07-19 15:16:36 -0500 (Mon, 19 Jul 2010) | 7 lines

    Avoid trying to pickup a parked extension before the park operation is completed.

    A crash could occur if the extension is picked up while the parking extension is
    being announced. Testing pu->notquiteyet while searching for a parked extension
    resolves this crash.

    (ABE-2418)
  ........
................

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.2@277966 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/features.c

index 260f7f5c955acdfe11cded80d2e4a9dc10f133e3..0668ae657f7bf962c6f998c8ce92d13b1eeff548 100644 (file)
@@ -3403,7 +3403,7 @@ static int park_exec_full(struct ast_channel *chan, void *data, struct ast_parki
 
        AST_LIST_LOCK(&parkinglot->parkings);
        AST_LIST_TRAVERSE_SAFE_BEGIN(&parkinglot->parkings, pu, list) {
-               if (!data || pu->parkingnum == park) {
+               if (!pu->notquiteyet && (!data || pu->parkingnum == park)) {
                        if (pu->chan->pbx) { /* do not allow call to be picked up until the PBX thread is finished */
                                AST_LIST_UNLOCK(&parkinglot->parkings);
                                return -1;