webdump

Fork of git://git.codemadness.org/webdump
git clone git://git.z3bra.org/webdump.git
Log | Files | Refs | README | LICENSE

commit 81fa07a9483e58eba2f9e4dae6349881fbb097f8
parent 0f33b39502a125c0761ecbec28e478392cd33a43
Author: Willy Goiffon <dev@z3bra.org>
Date:   Wed,  9 Oct 2019 19:56:25 +0200

Fix counting tags/depth

Diffstat:
webdump.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/webdump.c b/webdump.c @@ -575,10 +575,10 @@ xmltagend(XMLParser *p, const char *t, size_t tl, int isshort) if (!strcasecmp(t, "u")) fputs("\033[0m", stdout); } else if (!strcasecmp(t, "br")) { prvnode = curnode; - curnode--; fputs("\n", stdout); } + curnode--; } static void @@ -669,6 +669,7 @@ xmltagstartparsed(XMLParser *p, const char *t, size_t tl, int isshort) } else if (!strcasecmp(t, "hr")) { /* ruler */ for (i = 0; i < termwidth; i++) putchar('-'); + curnode--; } }