This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 145766 - dubious code in assert statements
dubious code in assert statements
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: libuser (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Miloslav Trmač
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-01-21 06:35 EST by David Binderman
Modified: 2007-11-30 17:10 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-03-04 15:54:05 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description David Binderman 2005-01-21 06:35:25 EST
Description of problem:

I just had a look at the source code for package libuser-0.53.2-1
from the Redhat Fedora development tree.

I found this

[root@localhost SPECS]# find ../BUILD/l* -name \*.c -print | xargs
grep "assert.*(.* = "
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);
../BUILD/libuser-0.53.2/modules/krb5.c: g_assert(ent->magic =
LU_ENT_MAGIC);

IMHO, dubious code. Suggest remove nested assignments from the assert
statement.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Miloslav Trmač 2005-03-04 15:54:05 EST
Thanks, fixed in CVS.
Not that the krb5 module would be possible to compile anyway...

Note You need to log in before you can comment on or make changes to this bug.