mirror of
https://github.com/X11Libre/xserver.git
synced 2026-04-14 17:18:09 +00:00
modesetting: Fix potential buffer overflow
If one misconfigures a ZaphodHeads value (more than 20 characters without a delimiter), we get an overflow of our buffer. Use xstrtokenize() instead of writing/fixing our own tokenizer. Signed-off-by: Daniel Martin <consume.noise@gmail.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
This commit is contained in:
committed by
Adam Jackson
parent
2230e6c8af
commit
04a305121f
@@ -233,7 +233,7 @@ padding_for_int32(const int bytes)
|
||||
}
|
||||
|
||||
|
||||
extern char **xstrtokenize(const char *str, const char *separators);
|
||||
extern _X_EXPORT char **xstrtokenize(const char *str, const char *separators);
|
||||
extern void FormatInt64(int64_t num, char *string);
|
||||
extern void FormatUInt64(uint64_t num, char *string);
|
||||
extern void FormatUInt64Hex(uint64_t num, char *string);
|
||||
|
||||
Reference in New Issue
Block a user