All pastes #363851 Raw Edit

Miscellany

public text v1 · immutable
#363851 ·published 2007-02-19 19:07 UTC
rendered paste body
# diff -u apps/app_meetme.c.orig apps/app_meetme.c
--- apps/app_meetme.c.orig      2007-02-19 11:23:21.000000000 -0700
+++ apps/app_meetme.c   2007-02-19 12:04:01.000000000 -0700
@@ -2011,7 +2011,13 @@
                                                        allowretry = 0;
                                                        /* see if we need to get rid of the conference */
                                                        ast_mutex_lock(&conflock);
-                                                       if (!cnf->users) {
+                                                       /*
+                                                        * MUST check for cnf not null.
+                                                        * If this is the second user, and the first user(conference creator) has hung up
+                                                        * The conference (cnf) has already been freed.
+                                                        * Really this could be an issue for this entire block begining at line 1962.
+                                                        */
+                                                       if (cnf && !cnf->users) {
                                                                conf_free(cnf);
                                                        }
                                                        ast_mutex_unlock(&conflock);