[tracker/miner-extractor-ipc] miner-fs: Fix reading memory out of bounds



commit 4b6369551cc51f96180c7673e6ba2850411c5a00
Author: Philip Van Hoof <philip codeminded be>
Date:   Thu Feb 24 16:31:39 2011 +0100

    miner-fs: Fix reading memory out of bounds

 src/miners/fs/tracker-miner-files.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/miners/fs/tracker-miner-files.c b/src/miners/fs/tracker-miner-files.c
index fcfc6f5..799ea49 100644
--- a/src/miners/fs/tracker-miner-files.c
+++ b/src/miners/fs/tracker-miner-files.c
@@ -2085,7 +2085,7 @@ flush_extract_queue_async_callback (SendAndSpliceData *data)
 					preupdate_length = strnlen (preupdate, buffer_size);
 					buffer_p += preupdate_length + 1;
 
-					if (preupdate_length < buffer_size && preupdate[buffer_size - 1] == '\0') {
+					if (preupdate_length < buffer_size) {
 						gint len;
 						/* sparql is stored just after preupdate in the original buffer */
 						sparql = preupdate + preupdate_length + 1;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]