From 9b95c86dfe4c1a3e347bc3f1613dfbaabbddf078 Mon Sep 17 00:00:00 2001 From: Mathieu Rene Date: Thu, 12 Feb 2009 20:56:59 +0000 Subject: [PATCH] s/^assert/switch_assert/ git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@11933 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/applications/mod_limit/mod_limit.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/mod/applications/mod_limit/mod_limit.c b/src/mod/applications/mod_limit/mod_limit.c index 32d22587d7..0c267656ea 100644 --- a/src/mod/applications/mod_limit/mod_limit.c +++ b/src/mod/applications/mod_limit/mod_limit.c @@ -391,13 +391,13 @@ SWITCH_STANDARD_API(db_api_function) goto error; } sql = switch_mprintf("delete from db_data where realm='%q' and data_key='%q'", argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); sql = switch_mprintf("insert into db_data (hostname, realm, data_key, data) values('%q','%q','%q','%q');", globals.hostname, argv[1], argv[2], argv[3]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); stream->write_function(stream, "+OK"); @@ -407,7 +407,7 @@ SWITCH_STANDARD_API(db_api_function) goto error; } sql = switch_mprintf("delete from db_data where realm='%q' and data_key='%q'", argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); stream->write_function(stream, "+OK"); @@ -609,12 +609,12 @@ SWITCH_STANDARD_API(group_api_function) goto error; } sql = switch_mprintf("delete from group_data where groupname='%q' and url='%q';", argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); sql = switch_mprintf("insert into group_data (hostname, groupname, url) values('%q','%q','%q');", globals.hostname, argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); stream->write_function(stream, "+OK"); @@ -628,7 +628,7 @@ SWITCH_STANDARD_API(group_api_function) } else { sql = switch_mprintf("delete from group_data where groupname='%q' and url='%q';", argv[1], argv[2]); } - assert(sql); + switch_assert(sql); limit_execute_sql(sql, NULL); switch_safe_free(sql); stream->write_function(stream, "+OK"); @@ -647,7 +647,7 @@ SWITCH_STANDARD_API(group_api_function) } sql = switch_mprintf("select url,'%q' from group_data where groupname='%q'", how, argv[1]); - assert(sql); + switch_assert(sql); limit_execute_sql_callback(NULL, sql, group_callback, &cbt); switch_safe_free(sql); @@ -690,12 +690,12 @@ SWITCH_STANDARD_APP(group_function) if (!strcasecmp(argv[0], "insert")) { sql = switch_mprintf("insert into group_data (hostname, groupname, url) values('%q','%q','%q');", globals.hostname, argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, globals.mutex); switch_safe_free(sql); } else if (!strcasecmp(argv[0], "delete")) { sql = switch_mprintf("delete from group_data where groupname='%q' and url='%q';", argv[1], argv[2]); - assert(sql); + switch_assert(sql); limit_execute_sql(sql, globals.mutex); switch_safe_free(sql); }