* Helmut Grohne <[email protected]>, 2012-06-23, 12:25:
+ while(<PKGCAT>)
+ {
+ if((not $incomment) and m/^-- update-catalog:nocheck --$/)
+ {
+ close(PKGCAT);
+ return 1;
+ }
+ s/--.*?--/ /g;
+ if(m/--/) {
+ if($incomment) {
+ s/.*?--//;
+ } else {
+ s/--.*//;
+ }
+ $incomment = 1 - $incomment;
+ }
+ if(m/CATALOG\s+(\S+)/) {
+ if(not -f $1) {
+ close(PKGCAT);
+ print "Warning: Ignoring catalog `$catalog' which references
non-existent catalogs. See man update-catalog for details.\n"
+ unless $quiet;
+ return 0;
+ }
+ }
+ }
I think is is overly simplistic. We should implement here a real TR9401
parser. This shouldn't be very difficult. I'll try to write such a
parser today.
Reference: https://www.oasis-open.org/specs/a401.htm
--
Jakub Wilk
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]