[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]
Strange bug in mp4h parsing
- From: Axel Beckert <nospam@thanx>
- Date: Mon, 24 Dec 2001 03:39:57 +0100
Hi!
I've got a strange parsing bug in mp4h (wml 2.0.7, system details at
the end of the email...):
If I use a <subst-in-string> inside a <define-tag> to make recursive
tag definitions, <subst-in-string> seems to require a space after the
first parameter and doesn't work, if there immediately follows a
newline after the first parameter. Maybe there are some more pedantic
circumstances necessary to reproduce this bug, but at least I could
reduce the complexity to the following to examples work the difference
out:
---8<---
# Doesn't work
<define-tag add_foo whitespace=delete>
<subst-in-string
"=LT=define-tag %0-only endtag=required>[%0:%%body:%0]=LT=/define-tag>"
"=LT=" "<" />
</define-tag>
<add_foo bar />
<bar-only>baz</bar-only>
# Works fine
<define-tag add_foo whitespace=delete>
<subst-in-string
"=LT=define-tag %0-only endtag=required>[%0:%%body:%0]=LT=/define-tag>"
"=LT=" "<" />
</define-tag>
<add_foo bar />
<bar-only>baz</bar-only>
--->8---
Please note the blank behind the second '=LT=/define-tag>"'! The result
of this piece of WML code is:
---8<---
=LT=define-tag bar-only endtag=required>[bar:%body:bar]=LT=/define-tag>=LT=
<bar-only>baz</bar-only>
[bar:baz:bar]
--->8---
Here's the full debugging data:
PLATFORM CHARACTERISTICS:
Used WML System:
Built Environment:
Host: sun4u-sun-solaris2.7
Perl: 5.006 (/usr/local/bin/perl)
User: axel@kathrin.dagstuhl.de
Date: 11-Jul-2001
Built Location:
Prefix: /usr/local
BinDir: /usr/local/bin
LibDir: /usr/local/lib/wml
ManDir: /usr/local/man
Used Perl System:
Summary of my perl5 (revision 5.0 version 6 subversion 1) configuration:
Platform:
osname=solaris, osvers=2.7, archname=sun4-solaris
uname='sunos kathrin 5.7 generic sun4u sparc '
config_args=''
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
useperlio=undef d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
Compiler:
cc='gcc', ccflags ='-fno-strict-aliasing -I/usr/local/include -I/opt/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
optimize='-O',
cppflags='-fno-strict-aliasing -I/usr/local/include -I/opt/local/include -I/opt/gnu/include'
ccversion='', gccversion='2.95.2 19991024 (release)', gccosandvers='solaris2.7'
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, usemymalloc=y, prototype=define
Linker and Libraries:
ld='gcc', ldflags =' -L/usr/local/lib -L/opt/local/lib -L/opt/gnu/lib '
libpth=/usr/local/lib /opt/local/lib /opt/gnu/lib /usr/lib /usr/ccs/lib
libs=-lsocket -lnsl -ldl -lm -lc
perllibs=-lsocket -lnsl -ldl -lm -lc
libc=/lib/libc.so, so=so, useshrplib=true, libperl=libperl.so
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' -Wl,-E -R /usr/local/lib/perl5/5.6.1/sun4-solaris/CORE'
cccdlflags='-fPIC', lddlflags=' -W,l-E -G -L/usr/local/lib -L/opt/local/lib -L/opt/gnu/lib'
Characteristics of this binary (from libperl):
Compile-time options: USE_LARGE_FILES
Built under solaris
Compiled at Jul 11 2001 13:53:17
@INC:
/usr/local/lib/perl5/5.6.1/sun4-solaris
/usr/local/lib/perl5/5.6.1
/usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris
/usr/local/lib/perl5/site_perl/5.6.1
/usr/local/lib/perl5/site_perl/5.6.0/sun4-solaris
/usr/local/lib/perl5/site_perl/5.6.0
/usr/local/lib/perl5/site_perl
.
Regards, Axel
--
Axel Beckert - abe@cs.uni-sb.de - http://abe.home.pages.de/
Student of Computer Science, University of Saarland (Germany)
Artificial Intelligence Laboratory (AI Lab), Prof. Dr. W. Wahlster;
WWW-/FTP-Administrator IBFI Schloß Dagstuhl; Students Representative CS
______________________________________________________________________
Website META Language (WML) www.engelschall.com/sw/wml/
Official Support Mailing List sw-wml@engelschall.com
Automated List Manager majordomo@engelschall.com