summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/core-util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/pulsecore/core-util.c')
-rw-r--r--src/pulsecore/core-util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pulsecore/core-util.c b/src/pulsecore/core-util.c
index 13d0bb5e..3eb12428 100644
--- a/src/pulsecore/core-util.c
+++ b/src/pulsecore/core-util.c
@@ -1823,7 +1823,7 @@ char *pa_hexstr(const uint8_t* d, size_t dlength, char *s, size_t slength) {
pa_assert(s);
pa_assert(slength > 0);
- while (i < dlength && j+3 <= slength) {
+ while (j+2 < slength && i < dlength) {
s[j++] = hex[*d >> 4];
s[j++] = hex[*d & 0xF];