Merged revisions 209760-209761 via svnmerge from

https://origsvn.digium.com/svn/asterisk/trunk

................
  r209760 | kpfleming | 2009-07-31 20:03:07 -0500 (Fri, 31 Jul 2009) | 13 lines
  
  Merged revisions 209759 via svnmerge from 
  https://origsvn.digium.com/svn/asterisk/branches/1.4
  
  ........
    r209759 | kpfleming | 2009-07-31 19:52:00 -0500 (Fri, 31 Jul 2009) | 7 lines
    
    Minor changes inspired by testing with latest GCC.
    
    The latest GCC (what will become 4.5.x) has a few new warnings, that in these
    cases found some either downright buggy code, or at least seriously poorly
    designed code that could be improved.
  ........
................
  r209761 | kpfleming | 2009-07-31 20:04:06 -0500 (Fri, 31 Jul 2009) | 1 line
  
  Revert accidental Makefile change.
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@209762 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin P. Fleming
2009-08-01 01:13:03 +00:00
parent 671e057fd7
commit db0581c7f0
5 changed files with 14 additions and 9 deletions

View File

@@ -248,7 +248,7 @@ static void dec_ie_bearer(unsigned char *p, Q931_info_t *qi, int *coding, int *c
if (p[0] <= octet) if (p[0] <= octet)
goto done; goto done;
if (!p[octet++] & 0x80) if (~p[octet++] & 0x80)
goto l2; goto l2;
/* Wheee. V.110 speed information */ /* Wheee. V.110 speed information */

View File

@@ -1924,9 +1924,7 @@ handle_event_nt(void *dat, void *arg)
case CC_SETUP|INDICATION: case CC_SETUP|INDICATION:
{ {
struct misdn_bchannel* bc=misdn_lib_get_free_bc(stack->port, 0, 1, 0); struct misdn_bchannel* bc=misdn_lib_get_free_bc(stack->port, 0, 1, 0);
if (!bc) if (!bc) {
ERR_NO_CHANNEL:
{
msg_t *dmsg; msg_t *dmsg;
cb_log(4, stack->port, "Patch from MEIDANIS:Sending RELEASE_COMPLETE %x (No free Chan for you..)\n", hh->dinfo); cb_log(4, stack->port, "Patch from MEIDANIS:Sending RELEASE_COMPLETE %x (No free Chan for you..)\n", hh->dinfo);
dmsg = create_l3msg(CC_RELEASE_COMPLETE | REQUEST,MT_RELEASE_COMPLETE, hh->dinfo,sizeof(RELEASE_COMPLETE_t), 1); dmsg = create_l3msg(CC_RELEASE_COMPLETE | REQUEST,MT_RELEASE_COMPLETE, hh->dinfo,sizeof(RELEASE_COMPLETE_t), 1);
@@ -2123,8 +2121,15 @@ handle_event_nt(void *dat, void *arg)
if (bc->channel<=0 || bc->channel==0xff) if (bc->channel<=0 || bc->channel==0xff)
bc->channel=0; bc->channel=0;
if (find_free_chan_in_stack(stack,bc, bc->channel,0)<0) if (find_free_chan_in_stack(stack,bc, bc->channel,0)<0) {
goto ERR_NO_CHANNEL; msg_t *dmsg;
cb_log(4, stack->port, "Patch from MEIDANIS:Sending RELEASE_COMPLETE %x (No free Chan for you..)\n", hh->dinfo);
dmsg = create_l3msg(CC_RELEASE_COMPLETE | REQUEST,MT_RELEASE_COMPLETE, hh->dinfo,sizeof(RELEASE_COMPLETE_t), 1);
pthread_mutex_lock(&stack->nstlock);
stack->nst.manager_l3(&stack->nst, dmsg);
free_msg(msg);
return 0;
}
break; break;
case EVENT_RELEASE: case EVENT_RELEASE:
case EVENT_RELEASE_COMPLETE: case EVENT_RELEASE_COMPLETE:

View File

@@ -102,7 +102,7 @@ editline/libedit.a: CHECK_SUBDIR
$(MAKE) -C editline libedit.a $(MAKE) -C editline libedit.a
db1-ast/libdb1.a: CHECK_SUBDIR db1-ast/libdb1.a: CHECK_SUBDIR
CFLAGS="$(subst $(ASTTOPDIR),../../,$(_ASTCFLAGS) $(ASTCFLAGS))" LDFLAGS="$(ASTLDFLAGS)" $(MAKE) -C db1-ast libdb1.a _ASTCFLAGS="$(_ASTCFLAGS)" ASTCFLAGS="$(ASTCFLAGS) -Wno-strict-aliasing" $(MAKE) -C db1-ast libdb1.a
ast_expr2.c ast_expr2.h: ast_expr2.c ast_expr2.h:
bison -o $@ -d --name-prefix=ast_yy ast_expr2.y bison -o $@ -d --name-prefix=ast_yy ast_expr2.y

View File

@@ -647,7 +647,7 @@ static int ast_event_dup_and_cache(const struct ast_event *event)
int ast_event_queue_and_cache(struct ast_event *event, ...) int ast_event_queue_and_cache(struct ast_event *event, ...)
{ {
va_list ap; va_list ap;
enum ast_event_type ie_type; enum ast_event_ie_type ie_type;
uint16_t host_event_type; uint16_t host_event_type;
struct ast_event_ref *event_ref; struct ast_event_ref *event_ref;
int res; int res;

View File

@@ -744,7 +744,7 @@ void checknoargs( int argcount, char *args[])
void parseargs( int argcount, char *args[], int fileswitch) void parseargs( int argcount, char *args[], int fileswitch)
{ {
char *filename; char *filename;
int tempint; int tempint = 0;
if ((fileswitch & 1) != 0) /* If getting infile */ if ((fileswitch & 1) != 0) /* If getting infile */
in = NULL; in = NULL;