[aide-tracker] [ aide-Bugs-1725719 ] @@else doesn't work
Brought to you by:
hvhaugwitz,
rvdb
From: SourceForge.net <no...@so...> - 2007-05-25 16:13:10
|
Bugs item #1725719, was opened at 2007-05-25 12:13 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581579&aid=1725719&group_id=86976 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Robby Griffin (alierak) Assigned to: Nobody/Anonymous (nobody) Summary: @@else doesn't work Initial Comment: It looks like processing of @@else is not fully implemented in aide 0.13.1. There are two logical cases for how @@else should be handled: 1. When handle_endif() is called with doit = 1; e.g., "@@undef FOO ... @@ifdef FOO", the conditional test has failed. In this case, we should skip input up to the @@else and continue processing. This is implemented. 2. When handle_endif() is called with doit = 0; e.g., "@define FOO bar ... @@ifdef FOO", the conditional test has passed. In this case, we should process everything up to @@else, then skip everything from @@else to @@endif. This is not implemented. What happens instead is that we process everything on both sides of the @@else (see also bug #1461215). I'm unfamiliar enough with lex / yacc that I don't see immediately how to fix this. Point me in the right direction and I may be able to work on it, though. A workaround for anyone maintaining aide.conf files: Replace: @@ifdef FOO ... @@else ... @@endif with: @@ifdef FOO ... @@endif @@ifndef FOO ... @@endif So, in fact, direct replacement of @@else with @@endif and the opposite conditional test might turn out to be a useful trick for the parser itself to do. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=581579&aid=1725719&group_id=86976 |