[svn-commits] branch oej/metermaids-trunk r35126 - in
/team/oej/metermaids-trunk: ./ build_...
svn-commits at lists.digium.com
svn-commits at lists.digium.com
Tue Jun 20 08:52:32 MST 2006
Author: oej
Date: Tue Jun 20 10:52:31 2006
New Revision: 35126
URL: http://svn.digium.com/view/asterisk?rev=35126&view=rev
Log:
Forced automerge
Modified:
team/oej/metermaids-trunk/ (props changed)
team/oej/metermaids-trunk/Makefile
team/oej/metermaids-trunk/ast_expr2.c
team/oej/metermaids-trunk/ast_expr2.fl
team/oej/metermaids-trunk/ast_expr2.h
team/oej/metermaids-trunk/ast_expr2.y
team/oej/metermaids-trunk/ast_expr2f.c
team/oej/metermaids-trunk/build_tools/menuselect.c
team/oej/metermaids-trunk/channels/chan_sip.c
team/oej/metermaids-trunk/channels/chan_skinny.c
Propchange: team/oej/metermaids-trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.2-blocked' - no diff available.
Propchange: team/oej/metermaids-trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.
Propchange: team/oej/metermaids-trunk/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Jun 20 10:52:31 2006
@@ -1,1 +1,1 @@
-/trunk:1-34916
+/trunk:1-35125
Modified: team/oej/metermaids-trunk/Makefile
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/Makefile?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/Makefile (original)
+++ team/oej/metermaids-trunk/Makefile Tue Jun 20 10:52:31 2006
@@ -359,8 +359,6 @@
HAVEDOT=no
endif
-INSTALL=install
-
_all: all
@echo " +--------- Asterisk Build Complete ---------+"
@echo " + Asterisk has successfully been built, but +"
@@ -423,10 +421,10 @@
ast_expr2f.c:
flex -o $@ --full ast_expr2.fl
-testexpr2: ast_expr2f.c ast_expr2.c ast_expr2.h
- gcc -g -c -DSTANDALONE ast_expr2f.c
- gcc -g -c -DSTANDALONE ast_expr2.c
- gcc -g -o testexpr2 ast_expr2f.o ast_expr2.o
+testexpr2: config.status include/asterisk/buildopts.h ast_expr2f.c ast_expr2.c ast_expr2.h
+ $(CC) -g -c -Iinclude -DSTANDALONE ast_expr2f.c
+ $(CC) -g -c -Iinclude -DSTANDALONE ast_expr2.c
+ $(CC) -g -o testexpr2 ast_expr2f.o ast_expr2.o
rm ast_expr2.o ast_expr2f.o
manpage: asterisk.8
Modified: team/oej/metermaids-trunk/ast_expr2.c
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/ast_expr2.c?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/ast_expr2.c (original)
+++ team/oej/metermaids-trunk/ast_expr2.c Tue Jun 20 10:52:31 2006
@@ -1,7 +1,9 @@
-/* A Bison parser, made by GNU Bison 2.1a. */
-
-/* Skeleton parser for Yacc-like parsing with Bison,
- Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+/* A Bison parser, made by GNU Bison 2.3. */
+
+/* Skeleton implementation for Bison's Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -18,10 +20,18 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
+/* As a special exception, you may create a larger work that contains
+ part or all of the Bison parser skeleton and distribute that work
+ under terms of your choice, so long as that work isn't itself a
+ parser generator using the skeleton or a modified version thereof
+ as a parser skeleton. Alternatively, if you modify or redistribute
+ the parser skeleton itself, you may (at your option) remove this
+ special exception, which will cause the skeleton and the resulting
+ Bison output files to be licensed under the GNU General Public
+ License without this special exception.
+
+ This special exception was added by the Free Software Foundation in
+ version 2.2 of Bison. */
/* C LALR(1) parser skeleton written by Richard Stallman, by
simplifying the original so-called "semantic" parser. */
@@ -37,7 +47,7 @@
#define YYBISON 1
/* Bison version. */
-#define YYBISON_VERSION "2.1a"
+#define YYBISON_VERSION "2.3"
/* Skeleton name. */
#define YYSKELETON_NAME "yacc.c"
@@ -131,7 +141,9 @@
#include "asterisk.h"
+#ifndef STANDALONE
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
+#endif
#include <sys/types.h>
#include <stdio.h>
@@ -272,12 +284,12 @@
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE
-#line 140 "ast_expr2.y"
+#line 147 "ast_expr2.y"
{
struct val *val;
}
-/* Line 198 of yacc.c. */
-#line 276 "ast_expr2.c"
+/* Line 193 of yacc.c. */
+#line 293 "ast_expr2.c"
YYSTYPE;
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
@@ -299,13 +311,13 @@
/* Copy the second part of user declarations. */
-#line 144 "ast_expr2.y"
+#line 151 "ast_expr2.y"
extern int ast_yylex __P((YYSTYPE *, YYLTYPE *, yyscan_t));
-/* Line 221 of yacc.c. */
-#line 304 "ast_expr2.c"
+/* Line 216 of yacc.c. */
+#line 321 "ast_expr2.c"
#ifdef short
# undef short
@@ -435,8 +447,13 @@
# ifndef YYSTACK_ALLOC_MAXIMUM
# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
# endif
-# ifdef __cplusplus
-extern "C" {
+# if (defined __cplusplus && ! defined _STDLIB_H \
+ && ! ((defined YYMALLOC || defined malloc) \
+ && (defined YYFREE || defined free)))
+# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
+# ifndef _STDLIB_H
+# define _STDLIB_H 1
+# endif
# endif
# ifndef YYMALLOC
# define YYMALLOC malloc
@@ -451,9 +468,6 @@
|| defined __cplusplus || defined _MSC_VER)
void free (void *); /* INFRINGES ON USER NAME SPACE */
# endif
-# endif
-# ifdef __cplusplus
-}
# endif
# endif
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
@@ -598,9 +612,9 @@
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
static const yytype_uint16 yyrline[] =
{
- 0, 168, 168, 176, 183, 184, 188, 192, 196, 200,
- 204, 208, 212, 216, 220, 224, 228, 232, 236, 240,
- 244, 248, 252, 256
+ 0, 175, 175, 183, 190, 191, 195, 199, 203, 207,
+ 211, 215, 219, 223, 227, 231, 235, 239, 243, 247,
+ 251, 255, 259, 263
};
#endif
@@ -858,14 +872,14 @@
#if (defined __STDC__ || defined __C99__FUNC__ \
|| defined __cplusplus || defined _MSC_VER)
static void
-yy_symbol_value_print (FILE *yyoutput, int yytype, const YYSTYPE * const yyvaluep, const YYLTYPE * const yylocationp)
+yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp)
#else
static void
yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp)
FILE *yyoutput;
int yytype;
- const YYSTYPE * const yyvaluep;
- const YYLTYPE * const yylocationp;
+ YYSTYPE const * const yyvaluep;
+ YYLTYPE const * const yylocationp;
#endif
{
if (!yyvaluep)
@@ -892,14 +906,14 @@
#if (defined __STDC__ || defined __C99__FUNC__ \
|| defined __cplusplus || defined _MSC_VER)
static void
-yy_symbol_print (FILE *yyoutput, int yytype, const YYSTYPE * const yyvaluep, const YYLTYPE * const yylocationp)
+yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp)
#else
static void
yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp)
FILE *yyoutput;
int yytype;
- const YYSTYPE * const yyvaluep;
- const YYLTYPE * const yylocationp;
+ YYSTYPE const * const yyvaluep;
+ YYLTYPE const * const yylocationp;
#endif
{
if (yytype < YYNTOKENS)
@@ -952,8 +966,7 @@
yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule)
#else
static void
-yy_reduce_print (yyvsp, yylsp, yyrule
- )
+yy_reduce_print (yyvsp, yylsp, yyrule)
YYSTYPE *yyvsp;
YYLTYPE *yylsp;
int yyrule;
@@ -1076,7 +1089,7 @@
{
if (*yystr == '"')
{
- size_t yyn = 0;
+ YYSIZE_T yyn = 0;
char const *yyp = yystr;
for (;;)
@@ -1123,7 +1136,7 @@
{
int yyn = yypact[yystate];
- if (! (YYPACT_NINF < yyn && yyn < YYLAST))
+ if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
return 0;
else
{
@@ -1161,7 +1174,7 @@
int yyxbegin = yyn < 0 ? -yyn : 0;
/* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn;
+ int yychecklim = YYLAST - yyn + 1;
int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
int yycount = 1;
@@ -1249,114 +1262,114 @@
switch (yytype)
{
case 3: /* "TOK_COLONCOLON" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1250 "ast_expr2.c"
+#line 1268 "ast_expr2.c"
break;
case 4: /* "TOK_COND" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1255 "ast_expr2.c"
+#line 1273 "ast_expr2.c"
break;
case 5: /* "TOK_OR" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1260 "ast_expr2.c"
+#line 1278 "ast_expr2.c"
break;
case 6: /* "TOK_AND" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1265 "ast_expr2.c"
+#line 1283 "ast_expr2.c"
break;
case 7: /* "TOK_NE" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1270 "ast_expr2.c"
+#line 1288 "ast_expr2.c"
break;
case 8: /* "TOK_LE" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1275 "ast_expr2.c"
+#line 1293 "ast_expr2.c"
break;
case 9: /* "TOK_GE" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1280 "ast_expr2.c"
+#line 1298 "ast_expr2.c"
break;
case 10: /* "TOK_LT" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1285 "ast_expr2.c"
+#line 1303 "ast_expr2.c"
break;
case 11: /* "TOK_GT" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1290 "ast_expr2.c"
+#line 1308 "ast_expr2.c"
break;
case 12: /* "TOK_EQ" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1295 "ast_expr2.c"
+#line 1313 "ast_expr2.c"
break;
case 13: /* "TOK_MINUS" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1300 "ast_expr2.c"
+#line 1318 "ast_expr2.c"
break;
case 14: /* "TOK_PLUS" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1305 "ast_expr2.c"
+#line 1323 "ast_expr2.c"
break;
case 15: /* "TOK_MOD" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1310 "ast_expr2.c"
+#line 1328 "ast_expr2.c"
break;
case 16: /* "TOK_DIV" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1315 "ast_expr2.c"
+#line 1333 "ast_expr2.c"
break;
case 17: /* "TOK_MULT" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1320 "ast_expr2.c"
+#line 1338 "ast_expr2.c"
break;
case 18: /* "TOK_COMPL" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1325 "ast_expr2.c"
+#line 1343 "ast_expr2.c"
break;
case 19: /* "TOK_EQTILDE" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1330 "ast_expr2.c"
+#line 1348 "ast_expr2.c"
break;
case 20: /* "TOK_COLON" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1335 "ast_expr2.c"
+#line 1353 "ast_expr2.c"
break;
case 21: /* "TOK_LP" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1340 "ast_expr2.c"
+#line 1358 "ast_expr2.c"
break;
case 22: /* "TOK_RP" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1345 "ast_expr2.c"
+#line 1363 "ast_expr2.c"
break;
case 23: /* "TOKEN" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1350 "ast_expr2.c"
+#line 1368 "ast_expr2.c"
break;
case 26: /* "expr" */
-#line 162 "ast_expr2.y"
+#line 169 "ast_expr2.y"
{ free_value((yyvaluep->val)); };
-#line 1355 "ast_expr2.c"
+#line 1373 "ast_expr2.c"
break;
default:
@@ -1679,7 +1692,7 @@
switch (yyn)
{
case 2:
-#line 168 "ast_expr2.y"
+#line 175 "ast_expr2.y"
{ ((struct parse_io *)parseio)->val = (struct val *)calloc(sizeof(struct val),1);
((struct parse_io *)parseio)->val->type = (yyvsp[(1) - (1)].val)->type;
if( (yyvsp[(1) - (1)].val)->type == AST_EXPR_integer )
@@ -1691,7 +1704,7 @@
break;
case 3:
-#line 176 "ast_expr2.y"
+#line 183 "ast_expr2.y"
{/* nothing */ ((struct parse_io *)parseio)->val = (struct val *)calloc(sizeof(struct val),1);
((struct parse_io *)parseio)->val->type = AST_EXPR_string;
((struct parse_io *)parseio)->val->u.s = strdup("");
@@ -1699,12 +1712,12 @@
break;
case 4:
-#line 183 "ast_expr2.y"
+#line 190 "ast_expr2.y"
{ (yyval.val)= (yyvsp[(1) - (1)].val);;}
break;
case 5:
-#line 184 "ast_expr2.y"
+#line 191 "ast_expr2.y"
{ (yyval.val) = (yyvsp[(2) - (3)].val);
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
(yyloc).first_line=0; (yyloc).last_line=0;
@@ -1712,7 +1725,7 @@
break;
case 6:
-#line 188 "ast_expr2.y"
+#line 195 "ast_expr2.y"
{ (yyval.val) = op_or ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1720,7 +1733,7 @@
break;
case 7:
-#line 192 "ast_expr2.y"
+#line 199 "ast_expr2.y"
{ (yyval.val) = op_and ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1728,7 +1741,7 @@
break;
case 8:
-#line 196 "ast_expr2.y"
+#line 203 "ast_expr2.y"
{ (yyval.val) = op_eq ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1736,7 +1749,7 @@
break;
case 9:
-#line 200 "ast_expr2.y"
+#line 207 "ast_expr2.y"
{ (yyval.val) = op_gt ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1744,7 +1757,7 @@
break;
case 10:
-#line 204 "ast_expr2.y"
+#line 211 "ast_expr2.y"
{ (yyval.val) = op_lt ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1752,7 +1765,7 @@
break;
case 11:
-#line 208 "ast_expr2.y"
+#line 215 "ast_expr2.y"
{ (yyval.val) = op_ge ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1760,7 +1773,7 @@
break;
case 12:
-#line 212 "ast_expr2.y"
+#line 219 "ast_expr2.y"
{ (yyval.val) = op_le ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1768,7 +1781,7 @@
break;
case 13:
-#line 216 "ast_expr2.y"
+#line 223 "ast_expr2.y"
{ (yyval.val) = op_ne ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1776,7 +1789,7 @@
break;
case 14:
-#line 220 "ast_expr2.y"
+#line 227 "ast_expr2.y"
{ (yyval.val) = op_plus ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1784,7 +1797,7 @@
break;
case 15:
-#line 224 "ast_expr2.y"
+#line 231 "ast_expr2.y"
{ (yyval.val) = op_minus ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1792,7 +1805,7 @@
break;
case 16:
-#line 228 "ast_expr2.y"
+#line 235 "ast_expr2.y"
{ (yyval.val) = op_negate ((yyvsp[(2) - (2)].val));
DESTROY((yyvsp[(1) - (2)].val));
(yyloc).first_column = (yylsp[(1) - (2)]).first_column; (yyloc).last_column = (yylsp[(2) - (2)]).last_column;
@@ -1800,7 +1813,7 @@
break;
case 17:
-#line 232 "ast_expr2.y"
+#line 239 "ast_expr2.y"
{ (yyval.val) = op_compl ((yyvsp[(2) - (2)].val));
DESTROY((yyvsp[(1) - (2)].val));
(yyloc).first_column = (yylsp[(1) - (2)]).first_column; (yyloc).last_column = (yylsp[(2) - (2)]).last_column;
@@ -1808,7 +1821,7 @@
break;
case 18:
-#line 236 "ast_expr2.y"
+#line 243 "ast_expr2.y"
{ (yyval.val) = op_times ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1816,7 +1829,7 @@
break;
case 19:
-#line 240 "ast_expr2.y"
+#line 247 "ast_expr2.y"
{ (yyval.val) = op_div ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1824,7 +1837,7 @@
break;
case 20:
-#line 244 "ast_expr2.y"
+#line 251 "ast_expr2.y"
{ (yyval.val) = op_rem ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1832,7 +1845,7 @@
break;
case 21:
-#line 248 "ast_expr2.y"
+#line 255 "ast_expr2.y"
{ (yyval.val) = op_colon ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1840,7 +1853,7 @@
break;
case 22:
-#line 252 "ast_expr2.y"
+#line 259 "ast_expr2.y"
{ (yyval.val) = op_eqtilde ((yyvsp[(1) - (3)].val), (yyvsp[(3) - (3)].val));
DESTROY((yyvsp[(2) - (3)].val));
(yyloc).first_column = (yylsp[(1) - (3)]).first_column; (yyloc).last_column = (yylsp[(3) - (3)]).last_column;
@@ -1848,7 +1861,7 @@
break;
case 23:
-#line 256 "ast_expr2.y"
+#line 263 "ast_expr2.y"
{ (yyval.val) = op_cond ((yyvsp[(1) - (5)].val), (yyvsp[(3) - (5)].val), (yyvsp[(5) - (5)].val));
DESTROY((yyvsp[(2) - (5)].val));
DESTROY((yyvsp[(4) - (5)].val));
@@ -1857,8 +1870,8 @@
break;
-/* Line 1270 of yacc.c. */
-#line 1857 "ast_expr2.c"
+/* Line 1267 of yacc.c. */
+#line 1875 "ast_expr2.c"
default: break;
}
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
@@ -2073,11 +2086,12 @@
if (yymsg != yymsgbuf)
YYSTACK_FREE (yymsg);
#endif
- return yyresult;
-}
-
-
-#line 263 "ast_expr2.y"
+ /* Make sure YYID is used. */
+ return YYID (yyresult);
+}
+
+
+#line 270 "ast_expr2.y"
static struct val *
Modified: team/oej/metermaids-trunk/ast_expr2.fl
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/ast_expr2.fl?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/ast_expr2.fl (original)
+++ team/oej/metermaids-trunk/ast_expr2.fl Tue Jun 20 10:52:31 2006
@@ -24,7 +24,9 @@
#include "asterisk.h"
+#ifndef STANDALONE
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
+#endif
#include <sys/types.h>
#include <stdio.h>
Modified: team/oej/metermaids-trunk/ast_expr2.h
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/ast_expr2.h?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/ast_expr2.h (original)
+++ team/oej/metermaids-trunk/ast_expr2.h Tue Jun 20 10:52:31 2006
@@ -1,7 +1,9 @@
-/* A Bison parser, made by GNU Bison 2.1a. */
+/* A Bison parser, made by GNU Bison 2.3. */
-/* Skeleton parser for Yacc-like parsing with Bison,
- Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+/* Skeleton interface for Bison's Yacc-like parsers in C
+
+ Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -18,10 +20,18 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, when this file is copied by Bison into a
- Bison output file, you may use that output file without restriction.
- This special exception was added by the Free Software Foundation
- in version 1.24 of Bison. */
+/* As a special exception, you may create a larger work that contains
+ part or all of the Bison parser skeleton and distribute that work
+ under terms of your choice, so long as that work isn't itself a
+ parser generator using the skeleton or a modified version thereof
+ as a parser skeleton. Alternatively, if you modify or redistribute
+ the parser skeleton itself, you may (at your option) remove this
+ special exception, which will cause the skeleton and the resulting
+ Bison output files to be licensed under the GNU General Public
+ License without this special exception.
+
+ This special exception was added by the Free Software Foundation in
+ version 2.2 of Bison. */
/* Tokens. */
#ifndef YYTOKENTYPE
@@ -80,12 +90,12 @@
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE
-#line 140 "ast_expr2.y"
+#line 147 "ast_expr2.y"
{
struct val *val;
}
-/* Line 1536 of yacc.c. */
-#line 89 "ast_expr2.h"
+/* Line 1529 of yacc.c. */
+#line 99 "ast_expr2.h"
YYSTYPE;
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
@@ -108,5 +118,3 @@
#endif
-
-
Modified: team/oej/metermaids-trunk/ast_expr2.y
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/ast_expr2.y?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/ast_expr2.y (original)
+++ team/oej/metermaids-trunk/ast_expr2.y Tue Jun 20 10:52:31 2006
@@ -14,7 +14,9 @@
#include "asterisk.h"
+#ifndef STANDALONE
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
+#endif
#include <sys/types.h>
#include <stdio.h>
Modified: team/oej/metermaids-trunk/ast_expr2f.c
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/ast_expr2f.c?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/ast_expr2f.c (original)
+++ team/oej/metermaids-trunk/ast_expr2f.c Tue Jun 20 10:52:31 2006
@@ -1356,7 +1356,9 @@
#include "asterisk.h"
+#ifndef STANDALONE
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
+#endif
#include <sys/types.h>
#include <stdio.h>
@@ -1421,7 +1423,7 @@
static int curlycount = 0;
static char *expr2_token_subst(char *mess);
-#line 1425 "ast_expr2f.c"
+#line 1427 "ast_expr2f.c"
#define INITIAL 0
#define var 1
@@ -1644,10 +1646,10 @@
register int yy_act;
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-#line 102 "ast_expr2.fl"
-
-
-#line 1651 "ast_expr2f.c"
+#line 104 "ast_expr2.fl"
+
+
+#line 1653 "ast_expr2f.c"
yylval = yylval_param;
@@ -1730,122 +1732,122 @@
case 1:
YY_RULE_SETUP
-#line 104 "ast_expr2.fl"
+#line 106 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_OR;}
YY_BREAK
case 2:
YY_RULE_SETUP
-#line 105 "ast_expr2.fl"
+#line 107 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_AND;}
YY_BREAK
case 3:
YY_RULE_SETUP
-#line 106 "ast_expr2.fl"
+#line 108 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_EQ;}
YY_BREAK
case 4:
YY_RULE_SETUP
-#line 107 "ast_expr2.fl"
+#line 109 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_OR;}
YY_BREAK
case 5:
YY_RULE_SETUP
-#line 108 "ast_expr2.fl"
+#line 110 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_AND;}
YY_BREAK
case 6:
YY_RULE_SETUP
-#line 109 "ast_expr2.fl"
+#line 111 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_EQ;}
YY_BREAK
case 7:
YY_RULE_SETUP
-#line 110 "ast_expr2.fl"
+#line 112 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_EQTILDE;}
YY_BREAK
case 8:
YY_RULE_SETUP
-#line 111 "ast_expr2.fl"
+#line 113 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_GT;}
YY_BREAK
case 9:
YY_RULE_SETUP
-#line 112 "ast_expr2.fl"
+#line 114 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_LT;}
YY_BREAK
case 10:
YY_RULE_SETUP
-#line 113 "ast_expr2.fl"
+#line 115 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_GE;}
YY_BREAK
case 11:
YY_RULE_SETUP
-#line 114 "ast_expr2.fl"
+#line 116 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_LE;}
YY_BREAK
case 12:
YY_RULE_SETUP
-#line 115 "ast_expr2.fl"
+#line 117 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_NE;}
YY_BREAK
case 13:
YY_RULE_SETUP
-#line 116 "ast_expr2.fl"
+#line 118 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_PLUS;}
YY_BREAK
case 14:
YY_RULE_SETUP
-#line 117 "ast_expr2.fl"
+#line 119 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_MINUS;}
YY_BREAK
case 15:
YY_RULE_SETUP
-#line 118 "ast_expr2.fl"
+#line 120 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_MULT;}
YY_BREAK
case 16:
YY_RULE_SETUP
-#line 119 "ast_expr2.fl"
+#line 121 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_DIV;}
YY_BREAK
case 17:
YY_RULE_SETUP
-#line 120 "ast_expr2.fl"
+#line 122 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_MOD;}
YY_BREAK
case 18:
YY_RULE_SETUP
-#line 121 "ast_expr2.fl"
+#line 123 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_COND;}
YY_BREAK
case 19:
YY_RULE_SETUP
-#line 122 "ast_expr2.fl"
+#line 124 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_COMPL;}
YY_BREAK
case 20:
YY_RULE_SETUP
-#line 123 "ast_expr2.fl"
+#line 125 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_COLON;}
YY_BREAK
case 21:
YY_RULE_SETUP
-#line 124 "ast_expr2.fl"
+#line 126 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_COLONCOLON;}
YY_BREAK
case 22:
YY_RULE_SETUP
-#line 125 "ast_expr2.fl"
+#line 127 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_LP;}
YY_BREAK
case 23:
YY_RULE_SETUP
-#line 126 "ast_expr2.fl"
+#line 128 "ast_expr2.fl"
{ SET_COLUMNS; SET_STRING; return TOK_RP;}
YY_BREAK
case 24:
YY_RULE_SETUP
-#line 127 "ast_expr2.fl"
+#line 129 "ast_expr2.fl"
{
/* gather the contents of ${} expressions, with trailing stuff,
* into a single TOKEN.
@@ -1858,24 +1860,24 @@
YY_BREAK
case 25:
YY_RULE_SETUP
-#line 137 "ast_expr2.fl"
+#line 139 "ast_expr2.fl"
{}
YY_BREAK
case 26:
/* rule 26 can match eol */
YY_RULE_SETUP
-#line 138 "ast_expr2.fl"
+#line 140 "ast_expr2.fl"
{SET_COLUMNS; SET_STRING; return TOKEN;}
YY_BREAK
case 27:
/* rule 27 can match eol */
YY_RULE_SETUP
-#line 140 "ast_expr2.fl"
+#line 142 "ast_expr2.fl"
{/* what to do with eol */}
YY_BREAK
case 28:
YY_RULE_SETUP
-#line 141 "ast_expr2.fl"
+#line 143 "ast_expr2.fl"
{
SET_COLUMNS;
/* the original behavior of the expression parser was
@@ -1887,7 +1889,7 @@
YY_BREAK
case 29:
YY_RULE_SETUP
-#line 150 "ast_expr2.fl"
+#line 152 "ast_expr2.fl"
{
SET_COLUMNS;
SET_STRING;
@@ -1897,7 +1899,7 @@
case 30:
/* rule 30 can match eol */
YY_RULE_SETUP
-#line 157 "ast_expr2.fl"
+#line 159 "ast_expr2.fl"
{
curlycount--;
if (curlycount < 0) {
@@ -1911,7 +1913,7 @@
case 31:
/* rule 31 can match eol */
YY_RULE_SETUP
-#line 167 "ast_expr2.fl"
+#line 169 "ast_expr2.fl"
{
curlycount++;
yymore();
@@ -1919,7 +1921,7 @@
YY_BREAK
case 32:
YY_RULE_SETUP
-#line 173 "ast_expr2.fl"
+#line 175 "ast_expr2.fl"
{
BEGIN(0);
SET_COLUMNS;
@@ -1930,7 +1932,7 @@
case 33:
/* rule 33 can match eol */
YY_RULE_SETUP
-#line 180 "ast_expr2.fl"
+#line 182 "ast_expr2.fl"
{
char c = yytext[yyleng-1];
BEGIN(0);
@@ -1942,7 +1944,7 @@
YY_BREAK
case 34:
YY_RULE_SETUP
-#line 189 "ast_expr2.fl"
+#line 191 "ast_expr2.fl"
{
curlycount = 0;
BEGIN(var);
@@ -1950,7 +1952,7 @@
}
YY_BREAK
case YY_STATE_EOF(trail):
-#line 195 "ast_expr2.fl"
+#line 197 "ast_expr2.fl"
{
BEGIN(0);
SET_COLUMNS;
@@ -1961,10 +1963,10 @@
YY_BREAK
case 35:
YY_RULE_SETUP
-#line 203 "ast_expr2.fl"
+#line 205 "ast_expr2.fl"
ECHO;
YY_BREAK
-#line 1968 "ast_expr2f.c"
+#line 1970 "ast_expr2f.c"
case YY_STATE_EOF(INITIAL):
case YY_STATE_EOF(var):
yyterminate();
@@ -2197,7 +2199,7 @@
/* Read in more data. */
YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
- yyg->yy_n_chars, num_to_read );
+ yyg->yy_n_chars, (size_t) num_to_read );
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
}
@@ -3091,7 +3093,7 @@
#define YYTABLES_NAME "yytables"
-#line 203 "ast_expr2.fl"
+#line 205 "ast_expr2.fl"
Modified: team/oej/metermaids-trunk/build_tools/menuselect.c
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/build_tools/menuselect.c?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/build_tools/menuselect.c (original)
+++ team/oej/metermaids-trunk/build_tools/menuselect.c Tue Jun 20 10:52:31 2006
@@ -683,7 +683,8 @@
exit(res);
/* Process module dependencies */
- res = process_deps();
+ if ((res = process_deps()))
+ exit(res);
/* The --check-deps option is used to ask this application to check to
* see if that an existing menuselect.makeopts file contails all of the
Modified: team/oej/metermaids-trunk/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/oej/metermaids-trunk/channels/chan_sip.c?rev=35126&r1=35125&r2=35126&view=diff
==============================================================================
--- team/oej/metermaids-trunk/channels/chan_sip.c (original)
+++ team/oej/metermaids-trunk/channels/chan_sip.c Tue Jun 20 10:52:31 2006
@@ -4509,7 +4509,6 @@
while ((m = get_sdp_iterate(&iterator, req, "m"))[0] != '\0') {
int x;
int audio = FALSE;
- numberofmediastreams++;
if (p->vrtp)
ast_rtp_pt_clear(newvideortp); /* Must be cleared in case no m=video line exists */
@@ -4517,6 +4516,7 @@
if ((sscanf(m, "audio %d/%d RTP/AVP %n", &x, &numberofports, &len) == 2) ||
(sscanf(m, "audio %d RTP/AVP %n", &x, &len) == 1)) {
audio = TRUE;
+ numberofmediastreams++;
/* Found audio stream in this media definition */
portno = x;
/* Scan through the RTP payload types specified in a "m=" line: */
@@ -4534,6 +4534,7 @@
(sscanf(m, "video %d RTP/AVP %n", &x, &len) == 1)) {
/* If it is not audio - is it video ? */
ast_clear_flag(&p->flags[0], SIP_NOVIDEO);
+ numberofmediastreams++;
vportno = x;
/* Scan through the RTP payload types specified in a "m=" line: */
for (codecs = m + len; !ast_strlen_zero(codecs); codecs = ast_skip_blanks(codecs + len)) {
@@ -4549,6 +4550,7 @@
if (debug)
ast_verbose("Got T.38 offer in SDP in dialog %s\n", p->callid);
udptlportno = x;
+ numberofmediastreams++;
if (p->owner && p->lastinvite) {
p->t38.state = T38_PEER_REINVITE; /* T38 Offered in re-invite from remote party */
@@ -4587,7 +4589,7 @@
return -2;
if (numberofmediastreams > 2)
- /* We have too many media streams, fail this offer */
+ /* We have too many fax, audio and/or video media streams, fail this offer */
return -3;
/* RTP addresses and ports for audio and video */
@@ -4634,23 +4636,19 @@
iterator = req->sdp_start;
while ((a = get_sdp_iterate(&iterator, req, "a"))[0] != '\0') {
char* mimeSubtype = ast_strdupa(a); /* ensures we have enough space */
- if (!strcasecmp(a, "sendonly")) {
- sendonly = 1;
- continue;
- } else if (!strcasecmp(a, "sendrecv")) {
- sendonly = 0;
- continue;
- } else if (option_debug) {
+ if (option_debug > 1) {
+ int breakout = FALSE;
+
/* If we're debugging, check for unsupported sdp options */
if (!strcasecmp(a, "inactive")) {
/* Inactive media streams: Not supported */
if (debug)
ast_verbose("Got unsupported a:inactive in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "rtcp:", (size_t) 5)) {
if (debug)
ast_verbose("Got unsupported a:rtcp in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "fmtp:", (size_t) 5)) {
/* Format parameters: Not supported */
/* Note: This is used for codec parameters, like bitrate for
@@ -4658,27 +4656,36 @@
See RFC2327 for an example */
if (debug)
ast_verbose("Got unsupported a:fmtp in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "framerate:", (size_t) 10)) {
/* Video stuff: Not supported */
if (debug)
ast_verbose("Got unsupported a:framerate in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "maxprate:", (size_t) 9)) {
/* Video stuff: Not supported */
if (debug)
ast_verbose("Got unsupported a:maxprate in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "crypto:", (size_t) 7)) {
/* SRTP stuff, not yet supported */
if (debug)
ast_verbose("Got unsupported a:crypto in SDP offer \n");
- continue;
+ breakout = TRUE;
} else if (!strncasecmp(a, "ptime:", (size_t) 6)) {
if (debug)
ast_verbose("Got unsupported a:ptime in SDP offer \n");
+ breakout = TRUE;
+ }
+ if (breakout) /* We have a match, skip to next header */
continue;
- }
+ }
+ if (!strcasecmp(a, "sendonly")) {
+ sendonly = 1;
+ continue;
+ } else if (!strcasecmp(a, "sendrecv")) {
+ sendonly = 0;
+ continue;
} else if (sscanf(a, "rtpmap: %u %[^/]/", &codec, mimeSubtype) != 2)
continue;
/* We have a rtpmap to handle */
@@ -4918,16 +4925,16 @@
/* Manager Hold and Unhold events must be generated, if necessary */
/* XXX Support for sendonly/recvonly needs to be fixed !!! */
if (sin.sin_addr.s_addr && !sendonly) {
- append_history(p, "Unhold", "%s", req->data);
-
- if (global_callevents && ast_test_flag(&p->flags[0], SIP_CALL_ONHOLD)) {
- manager_event(EVENT_FLAG_CALL, "Unhold",
- "Channel: %s\r\n"
- "Uniqueid: %s\r\n",
- p->owner->name,
- p->owner->uniqueid);
-
- }
+ if (ast_test_flag(&p->flags[0], SIP_CALL_ONHOLD)) {
+ append_history(p, "Unhold", "%s", req->data);
+ if (global_callevents)
+ manager_event(EVENT_FLAG_CALL, "Unhold",
+ "Channel: %s\r\n"
+ "Uniqueid: %s\r\n",
+ p->owner->name,
+ p->owner->uniqueid);
+
+ }
ast_clear_flag(&p->flags[0], SIP_CALL_ONHOLD);
} else {
/* No address for RTP, we're on hold */
@@ -7607,6 +7614,26 @@
const char *reqheader = "Proxy-Authorization";
const char *respheader = "Proxy-Authenticate";
const char *authtoken;
+ char a1_hash[256];
+ char resp_hash[256]="";
+ char tmp[BUFSIZ * 2]; /* Make a large enough buffer */
+ char *c;
+ int wrongnonce = FALSE;
+ int good_response;
+ const char *usednonce = p->randdata;
+
+ /* table of recognised keywords, and their value in the digest */
+ enum keys { K_RESP, K_URI, K_USER, K_NONCE, K_LAST };
+ struct x {
+ const char *key;
+ const char *s;
+ } *i, keys[] = {
+ [K_RESP] = { "response=", "" },
+ [K_URI] = { "uri=", "" },
+ [K_USER] = { "username=", "" },
+ [K_NONCE] = { "nonce=", "" },
+ [K_LAST] = { NULL, NULL}
+ };
/* Always OK if no secret */
if (ast_strlen_zero(secret) && ast_strlen_zero(md5secret))
@@ -7638,120 +7665,102 @@
/* Schedule auto destroy in 32 seconds */
sip_scheddestroy(p, SIP_TRANS_TIMEOUT);
return AUTH_CHALLENGE_SENT;
- } else { /* We have auth, so check it */
-
- /* XXX reduce nesting here */
-
- /* Whoever came up with the authentication section of SIP can suck my %&#$&* for not putting
- an example in the spec of just what it is you're doing a hash on. */
- char a1_hash[256];
- char resp_hash[256]="";
- char tmp[256];
- char *c;
- int wrongnonce = FALSE;
- int good_response;
- const char *usednonce = p->randdata; /* XXX check */
-
- /* table of recognised keywords, and their value in the digest */
- enum keys { K_RESP, K_URI, K_USER, K_NONCE, K_LAST };
- struct x {
- const char *key;
- const char *s;
- } *i, keys[] = {
- [K_RESP] = { "response=", "" },
- [K_URI] = { "uri=", "" },
- [K_USER] = { "username=", "" },
- [K_NONCE] = { "nonce=", "" },
- [K_LAST] = { NULL, NULL}
- };
-
- /* Make a copy of the response and parse it */
- ast_copy_string(tmp, authtoken, sizeof(tmp));
- c = tmp;
-
- while(c && *(c = ast_skip_blanks(c)) ) { /* lookup for keys */
- for (i = keys; i->key != NULL; i++) {
- const char *separator = ","; /* default */
-
- if (strncasecmp(c, i->key, strlen(i->key)) != 0)
- continue;
- /* Found. Skip keyword, take text in quotes or up to the separator. */
- c += strlen(i->key);
- if (*c == '"') { /* in quotes. Skip first and look for last */
- c++;
- separator = "\"";
- }
- i->s = c;
- strsep(&c, separator);
- break;
+ }
+
+ /* --- We have auth, so check it */
+
+ /* Whoever came up with the authentication section of SIP can suck my %&#$&* for not putting
+ an example in the spec of just what it is you're doing a hash on. */
+
+
+ /* Make a copy of the response and parse it */
+ ast_copy_string(tmp, authtoken, sizeof(tmp));
+ c = tmp;
+
+ while(c && *(c = ast_skip_blanks(c)) ) { /* lookup for keys */
+ for (i = keys; i->key != NULL; i++) {
+ const char *separator = ","; /* default */
+
+ if (strncasecmp(c, i->key, strlen(i->key)) != 0)
+ continue;
+ /* Found. Skip keyword, take text in quotes or up to the separator. */
+ c += strlen(i->key);
[... 247 lines stripped ...]
More information about the svn-commits
mailing list