-
Notifications
You must be signed in to change notification settings - Fork 319
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
xml: Add capability to properly encode xml entities in context attrib…
…utes Per #519, xml entities (<, >, ", ', and &) were not encoded properly, and if used in the libiio.ini file (which was added in 77568c7 ) cause the libiio library to fail. This fixed that by adding a generic way to encode things in xml.c and uses them in context.c Right now, we only encode context attributes. In theory this could also effect: - attribute name - buffer-attribute name - channel id - context name - debug-attribute name - device id - scan-element index Since most of those are encoded in file names, we shouldn't have those chars anyway. Now that we know the issue, and understand the fix, if anyone sees any issues, please feel free to report. Tested on Zed + FMCOMMS3, with both 0.19 (with fix) and old libraries without fix. As long as the the version which is reading the file has the fix - it works with older libraries (is backwards compatible). Signed-off-by: Robin Getz <[email protected]>
- Loading branch information
Showing
3 changed files
with
48 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters