diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/plist.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/plist.c b/src/plist.c index 569251b..3e69e2a 100644 --- a/src/plist.c +++ b/src/plist.c | |||
| @@ -49,6 +49,15 @@ void plist_cleanup(void) | |||
| 49 | xmlCleanupMemory(); | 49 | xmlCleanupMemory(); |
| 50 | } | 50 | } |
| 51 | 51 | ||
| 52 | PLIST_API int plist_is_binary(const char *plist_data, uint32_t length) | ||
| 53 | { | ||
| 54 | if (length < 8) { | ||
| 55 | return 0; | ||
| 56 | } | ||
| 57 | |||
| 58 | return (memcmp(plist_data, "bplist00", 8) == 0); | ||
| 59 | } | ||
| 60 | |||
| 52 | plist_t plist_new_node(plist_data_t data) | 61 | plist_t plist_new_node(plist_data_t data) |
| 53 | { | 62 | { |
| 54 | return (plist_t) node_create(NULL, data); | 63 | return (plist_t) node_create(NULL, data); |
