Jim Gallacher wrote .. > Jim Gallacher wrote: > > Graham Dumpleton wrote: > >> Jim Gallacher wrote .. > >>> Although there is no JIRA issue for it, I'd like to see us do a quick > >>> code cleanup. I see lots of complier warnings about unused variables > and > >>> it would be nice to excise the offending bits of code. I figure we > are > >>> more likely to spot real problems if the compiler is spewing less noise. > >>> If there are no objections I'll do this over the weekend. > >> > >> Hmmm, I thought I had gone through and got rid of just about all of > them. > >> The only ones which I didn't fix up were some of the magic Python > >> callbacks > >> for deleting objects or something. I couldn't change these as I don't > >> think > >> some appropriate typedef or something existed in older versions of Python > >> we still support. > > > > You may well be correct. It's been a while since I sat and watched the > > compiler output and that may have been when I was doing some leak > > testing on 3.2.10. > > > I did a quick check on r466129 and it looks pretty good. There are still > a couple outstanding instances however. It looks like they are in code > that you worked on, Graham. (Not really a surprise, since you've worked > on almost all of the code. ;) ) I can't see any harm in deleting the > offending bits, but perhaps you could review just to make sure lines are > in fact superfluous, as opposed to a lurking bug. > > mod_python.c:2437: warning: unused variable 'srv_conf' > mod_python.c:2677: warning: unused variable 'ppath' > requestobject.c:535: warning: unused variable 'result' > requestobject.c:554: warning: unused variable 'result' > requestobject.c:658: warning: unused variable 'result'
My compiler doesn't pick these up. I have though deleted or commented them out where appropriate. I was about to commit changes back along with some new log functions, but the Subversion repository has been taken offline. So, I'll do it when it comes back .... :-( Graham
