Skip to content

Commit

Permalink
[misc] Add misc_xml.c to wrap mxml, fixes XML reading of CDATA (et al)
Browse files Browse the repository at this point in the history
The change removes all direct calls to mxml from the modules that need an XML
parser (lastfm.c, pipe.c, rssscanner.c and httpd_rsp.c).

Even with the help of mxml, reading XML is hard, so a layer is added which
helps deal with stuff like whitespace and CDATA. This should make OwnTone more
resilient to any XML variations it might receive.

The changes fixes issue #1677.
  • Loading branch information
ejurgensen committed Nov 12, 2023
1 parent 83ac327 commit 65c72c4
Show file tree
Hide file tree
Showing 8 changed files with 654 additions and 503 deletions.
2 changes: 1 addition & 1 deletion src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ owntone_SOURCES = main.c \
artwork.c artwork.h \
misc.c misc.h \
misc_json.c misc_json.h \
misc_xml.c misc_xml.h \
rng.c rng.h \
smartpl_query.c smartpl_query.h \
player.c player.h \
Expand All @@ -128,7 +129,6 @@ owntone_SOURCES = main.c \
$(MPD_SRC) \
listener.c listener.h \
commands.c commands.h \
mxml-compat.h \
outputs/plist_wrap.h \
$(LIBWEBSOCKETS_SRC) \
$(GPERF_SRC) \
Expand Down
Loading

0 comments on commit 65c72c4

Please sign in to comment.