[asterisk-commits] seanbright: branch seanbright/resolve-shadow-warnings r125479 - in /team/sean...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jun 26 16:07:15 CDT 2008


Author: seanbright
Date: Thu Jun 26 16:07:14 2008
New Revision: 125479

URL: http://svn.digium.com/view/asterisk?view=rev&rev=125479
Log:
Merged revisions 125332-125333,125385-125386,125438,125477 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r125332 | russell | 2008-06-26 11:37:01 -0400 (Thu, 26 Jun 2008) | 5 lines

- add get_max_rate timing API call
- change ast_settimeout() to honor max rate in edge cases of file playback
  (this will make some warning messages go away at the end of playing back
   a file)

................
r125333 | kpfleming | 2008-06-26 11:50:07 -0400 (Thu, 26 Jun 2008) | 13 lines

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

........
r125327 | kpfleming | 2008-06-26 10:30:33 -0500 (Thu, 26 Jun 2008) | 5 lines

ensure that (whenever possible) if we generate a log message because an ioctl() call to DAHDI/Zaptel failed, that we include the reason it failed by including the stringified error number

(issue AST-80)


........

................
r125385 | oej | 2008-06-26 12:54:22 -0400 (Thu, 26 Jun 2008) | 12 lines


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

........
r125384 | oej | 2008-06-26 18:32:08 +0200 (Tor, 26 Jun 2008) | 3 lines

Add support for peer realm based auth (a few missing lines, the rest is well documented but never worked)


........

................
r125386 | tilghman | 2008-06-26 13:06:17 -0400 (Thu, 26 Jun 2008) | 6 lines

Convert casts to unions, to fix alignment issues on Solaris
(closes issue #12932)
 Reported by: snuffy
 Patches: 
       bug_12932_20080627.diff uploaded by snuffy (license 35)

................
r125438 | tilghman | 2008-06-26 13:40:25 -0400 (Thu, 26 Jun 2008) | 6 lines

Don't play "your message has been saved" twice.
(closes issue #12893)
 Reported by: jaroth
 Patches: 
       duplicate_saved.patch uploaded by jaroth (license 50)

................
r125477 | mmichelson | 2008-06-26 16:57:41 -0400 (Thu, 26 Jun 2008) | 19 lines

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

........
r125476 | mmichelson | 2008-06-26 15:56:01 -0500 (Thu, 26 Jun 2008) | 11 lines

Prior to this patch, the "queue show" command used cached
information for realtime queues instead of giving up-to-date
info. Now realtime is queried for the latest and greatest in
queue info.

(closes issue #12858)
Reported by: bcnit
Patches:
      queue_show.patch uploaded by putnopvut (license 60)


........

................

Modified:
    team/seanbright/resolve-shadow-warnings/   (props changed)
    team/seanbright/resolve-shadow-warnings/apps/app_queue.c

Propchange: team/seanbright/resolve-shadow-warnings/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu Jun 26 16:07:14 2008
@@ -1,1 +1,1 @@
-/trunk:1-125323
+/trunk:1-125478

Modified: team/seanbright/resolve-shadow-warnings/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/resolve-shadow-warnings/apps/app_queue.c?view=diff&rev=125479&r1=125478&r2=125479
==============================================================================
--- team/seanbright/resolve-shadow-warnings/apps/app_queue.c (original)
+++ team/seanbright/resolve-shadow-warnings/apps/app_queue.c Thu Jun 26 16:07:14 2008
@@ -5438,9 +5438,19 @@
 	if (argc != 2 && argc != 3)
 		return CLI_SHOWUSAGE;
 
-	/* We only want to load realtime queues when a specific queue is asked for. */
-	if (argc == 3)	/* specific queue */
+	if (argc == 3)	{ /* specific queue */
 		load_realtime_queue(argv[2]);
+	}
+	else if (ast_check_realtime("queues")) {
+		struct ast_config *cfg = ast_load_realtime_multientry("queues", "name LIKE", "%", SENTINEL);
+		char *queuename;
+		if (cfg) {
+			for (queuename = ast_category_browse(cfg, NULL); !ast_strlen_zero(queuename); queuename = ast_category_browse(cfg, queuename)) {
+				load_realtime_queue(queuename);
+			}
+			ast_config_destroy(cfg);
+		}
+	}
 
 	queue_iter = ao2_iterator_init(queues, 0);
 	while ((q = ao2_iterator_next(&queue_iter))) {
@@ -5506,11 +5516,15 @@
 		}
 		do_print(s, fd, "");	/* blank line between entries */
 		ao2_unlock(q);
-		if (argc == 3)	{ /* print a specific entry */
+		if (q->realtime || argc == 3) {
+			/* If a queue is realtime, then that means we used load_realtime_queue() above
+			 * to get its information. This means we have an extra reference we need to
+			 * remove at this point. If a specific queue was requested, then it also needs
+			 * to be unreffed here even if it is not a realtime queue.
+			 */
 			queue_unref(q);
-			break;
-		}
-		queue_unref(q);
+		}
+		queue_unref(q); /* Unref the iterator's reference */
 	}
 	if (!found) {
 		if (argc == 3)




More information about the asterisk-commits mailing list