Drop the reference count on the correct object.
authorJoshua Colp <jcolp@digium.com>
Tue, 23 Jul 2013 18:41:29 +0000 (18:41 +0000)
committerJoshua Colp <jcolp@digium.com>
Tue, 23 Jul 2013 18:41:29 +0000 (18:41 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@395183 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_gulp.c

index e3d3ed0..dbc6d4f 100644 (file)
@@ -1510,7 +1510,7 @@ static int hangup(void *data)
        }
 
        clear_session_and_channel(session, ast, pvt);
-       ao2_cleanup(pvt);
+       ao2_cleanup(channel);
        ao2_cleanup(h_data);
 
        return 0;
@@ -1540,7 +1540,7 @@ failure:
         * to be able to send our SIP request/response
         */
        clear_session_and_channel(channel->session, ast, pvt);
-       ao2_cleanup(pvt);
+       ao2_cleanup(channel);
        ao2_cleanup(h_data);
 
        return -1;