[asterisk-bugs] [Asterisk 0012120]: [patch] unnecessary complex expression in last build_user() modification
noreply at bugs.digium.com
noreply at bugs.digium.com
Mon Mar 3 09:11:51 CST 2008
The following issue has been ASSIGNED.
======================================================================
http://bugs.digium.com/view.php?id=12120
======================================================================
Reported By: flefoll
Assigned To: file
======================================================================
Project: Asterisk
Issue ID: 12120
Category: Channels/chan_sip/General
Reproducibility: always
Severity: minor
Priority: normal
Status: assigned
Asterisk Version: SVN
SVN Branch (only for SVN checkouts, not tarball releases): 1.4
SVN Revision (number only!): 104095
Disclaimer on File?: N/A
Request Review:
======================================================================
Date Submitted: 03-03-2008 03:19 CST
Last Modified: 03-03-2008 09:11 CST
======================================================================
Summary: [patch] unnecessary complex expression in last
build_user() modification
Description:
An additional "alt" argument was introduced for build_user() in chan_sip.c
rev 104095, and exit condition in for() loop was modified.
But I read it and read it again, and I can't see any difference between
former
for (; v; v = v->next)
and new
for (; v || ((v = alt) && !(alt=NULL)); v = v->next)
In both cases, the exit condition can be summarized to "v is not NULL".
But I think that former expression is much more readable.
======================================================================
----------------------------------------------------------------------
svnbot - 03-03-08 09:11
----------------------------------------------------------------------
Repository: asterisk
Revision: 105557
U branches/1.4/channels/chan_sip.c
------------------------------------------------------------------------
r105557 | file | 2008-03-03 09:11:48 -0600 (Mon, 03 Mar 2008) | 6 lines
Add a comment to describe some logic.
(closes issue http://bugs.digium.com/view.php?id=12120)
Reported by: flefoll
Patches:
chan_sip.c.br14.patch-just-a-comment uploaded by flefoll (license
244)
------------------------------------------------------------------------
http://svn.digium.com/view/asterisk?view=rev&revision=105557
Issue History
Date Modified Username Field Change
======================================================================
03-03-08 09:11 svnbot Note Added: 0083257
03-03-08 09:11 svnbot Status new => assigned
03-03-08 09:11 svnbot Assigned To => file
======================================================================
More information about the asterisk-bugs
mailing list