Page MenuHomeFreeBSD

change uneeded const
ClosedPublic

Authored by sbruno on Jul 19 2014, 2:23 AM.
Tags
None
Referenced Files
F106737555: D445.diff
Sat, Jan 4, 4:10 PM
Unknown Object (File)
Oct 27 2024, 2:38 AM
Unknown Object (File)
Oct 19 2024, 1:18 PM
Unknown Object (File)
Oct 3 2024, 1:18 PM
Unknown Object (File)
Oct 3 2024, 9:03 AM
Unknown Object (File)
Oct 2 2024, 9:14 PM
Unknown Object (File)
Oct 2 2024, 7:36 PM
Unknown Object (File)
Oct 2 2024, 2:07 PM
Subscribers
None

Details

Reviewers
grehan
neel
Summary

another warning squash

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

sbruno retitled this revision from to change uneeded const.
sbruno updated this object.
sbruno edited the test plan for this revision. (Show Details)
sbruno added reviewers: grehan, neel.

Wouldn't this create another warning at line 112 because 'devspec' is a const and is now assigned to a non-const variable?
np = (devspec + strlen(dv->dv_name));

sbruno edited edge metadata.

Instead of changing the qualifier on np to non-const, change the assignment of the pointer to cp
with a cast of np to remove the const. This lets the compiler know we looked at it.

Conserve const qualifiers and cast the strtol() use

neel edited edge metadata.

Looks good.

This revision is now accepted and ready to land.Aug 8 2014, 9:44 PM

committed at svn revsion 269741.