return out;
}
-static const char content_description_header[] = {
+static const uint8_t content_description_header[] = {
0x33, 0x26, 0xb2, 0x75, 0x8E, 0x66, 0xCF, 0x11,
0xa6, 0xd9, 0x00, 0xaa, 0x00, 0x62, 0xce, 0x6c
};
-static const char extended_content_header[] = {
+static const uint8_t extended_content_header[] = {
0x40, 0xA4, 0xD0, 0xD2, 0x07, 0xE3, 0xD2, 0x11,
0x97, 0xF0, 0x00, 0xA0, 0xC9, 0x5E, 0xA8, 0x50
};
-static const char year_tag_header[] = { /* WM/Year */
+static const uint8_t year_tag_header[] = { /* WM/Year */
0x57, 0x00, 0x4d, 0x00, 0x2f, 0x00, 0x59, 0x00,
0x65, 0x00, 0x61, 0x00, 0x72, 0x00
};
-static const char album_tag_header[] = { /* WM/AlbumTitle */
+static const uint8_t album_tag_header[] = { /* WM/AlbumTitle */
0x57, 0x00, 0x4d, 0x00, 0x2f, 0x00, 0x41, 0x00,
0x6c, 0x00, 0x62, 0x00, 0x75, 0x00, 0x6d, 0x00,
0x54, 0x00, 0x69, 0x00, 0x74, 0x00, 0x6c, 0x00,
return 1;
}
-static const char top_level_header_object_guid[] = {
+static const uint8_t top_level_header_object_guid[] = {
0x30, 0x26, 0xb2, 0x75, 0x8e, 0x66, 0xcf, 0x11,
0xa6, 0xd9, 0x00, 0xaa, 0x00, 0x62, 0xce, 0x6c
};
*
* \return A pointer into \a buf or \p NULL if the pattern was not found.
*/
-const char *search_pattern(const char *pattern, int pattern_len,
+const char *search_pattern(const uint8_t *pattern, int pattern_len,
const char *buf, int buf_size)
{
const char *p, *end = buf + buf_size;
static int find_file_properties(const char *buf, int len)
{
- const char pattern[] = {0xa1, 0xdc, 0xab, 0x8c};
+ const uint8_t pattern[] = {0xa1, 0xdc, 0xab, 0x8c};
const char *p = search_pattern(pattern, sizeof(pattern), buf, len);
if (!p)
return p - buf + 16;
}
-/*
- 40 9e 69 f8 4d 5b cf 11 a8 fd 00 80 5f 5c 44 2b
- */
+/* 40 9e 69 f8 4d 5b cf 11 a8 fd 00 80 5f 5c 44 2b */
static int find_audio_stream_info(const char *buf, int len)
{
- const char pattern[] = {0x40, 0x9e, 0x69, 0xf8};
+ const uint8_t pattern[] = {0x40, 0x9e, 0x69, 0xf8};
const char *p = search_pattern(pattern, sizeof(pattern), buf, len);
if (!p)