From 6347a1c9d9c13bd05b12777f1c5efbd9104c83c1 Mon Sep 17 00:00:00 2001 From: Matthew Dillon Date: Sun, 17 Jun 2007 07:36:28 +0000 Subject: [PATCH] Lines in /etc/uuids[.local] beginning with '#' are considered comments. --- lib/libc/uuid/uuid_name_lookup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libc/uuid/uuid_name_lookup.c b/lib/libc/uuid/uuid_name_lookup.c index 9056eadcd..7f8da9a50 100644 --- a/lib/libc/uuid/uuid_name_lookup.c +++ b/lib/libc/uuid/uuid_name_lookup.c @@ -31,7 +31,7 @@ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $DragonFly: src/lib/libc/uuid/uuid_name_lookup.c,v 1.1 2007/06/17 07:35:12 dillon Exp $ + * $DragonFly: src/lib/libc/uuid/uuid_name_lookup.c,v 1.2 2007/06/17 07:36:28 dillon Exp $ */ /* * Implement UUID-to-NAME and NAME-to-UUID functions @@ -194,7 +194,7 @@ uuid_loadcache(const char *path) if ((fp = fopen(path, "r")) == NULL) return; while ((line = fgetln(fp, &len)) != NULL) { - if (len == 0) + if (len == 0 || *line == '#') continue; line[len-1] = 0; uuid = strtok_r(line, " \t\r", &last); -- 2.11.4.GIT