From 803d3095df83f1e87372bf7b14f0041394458b0a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thomas=20Wei=C3=9Fschuh?= Date: Sat, 30 Sep 2023 23:55:31 +0200 Subject: [PATCH] libblkid: (probe) add magic hint MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This hint can be used by the probing callback to make decision based on the matched magic. This avoids a awkward memcmp() on the magic string. Signed-off-by: Thomas Weißschuh --- libblkid/src/blkidP.h | 1 + 1 file changed, 1 insertion(+) diff --git a/libblkid/src/blkidP.h b/libblkid/src/blkidP.h index fb91185d0b..a02df7eb6f 100644 --- a/libblkid/src/blkidP.h +++ b/libblkid/src/blkidP.h @@ -146,6 +146,7 @@ struct blkid_idmag { const char *magic; /* magic string */ unsigned int len; /* length of magic */ + unsigned int hint; /* hint for prober */ const char *hoff; /* hint which contains byte offset to kboff */ long kboff; /* kilobyte offset of superblock */ -- 2.47.3