Index: uspace/srv/vfs/vfs.h
===================================================================
--- uspace/srv/vfs/vfs.h	(revision 5832e9b1dbc9ea6730f610f94bf8bdfaadc56c42)
+++ uspace/srv/vfs/vfs.h	(revision cc76be3943a308c0e7ce268a92c9c99a4b60a84c)
@@ -84,5 +84,5 @@
 typedef struct {
 	/** Unique identifier of the fs. */
-	char name[FS_NAME_MAXLEN];
+	char name[FS_NAME_MAXLEN + 1];
 	
 	/** Operations. */
Index: uspace/srv/vfs/vfs_register.c
===================================================================
--- uspace/srv/vfs/vfs_register.c	(revision 5832e9b1dbc9ea6730f610f94bf8bdfaadc56c42)
+++ uspace/srv/vfs/vfs_register.c	(revision cc76be3943a308c0e7ce268a92c9c99a4b60a84c)
@@ -88,4 +88,12 @@
 			}
 		}
+	}
+	/*
+	 * This check is not redundant. It ensures that the name is
+	 * NULL-terminated, even if FS_NAME_MAXLEN characters are used.
+	 */
+	if (info->name[i] != '\0') {
+		dprintf("The name is not properly NULL-terminated.\n");	
+		return false;
 	}
 	
@@ -401,5 +409,6 @@
 	for (cur = fs_head.next; cur != &fs_head; cur = cur->next) {
 		fs_info_t *fs = list_get_instance(cur, fs_info_t, fs_link);
-		if (strcmp(fs->vfs_info.name, name) == 0) { /* XXX: strncmp() */
+		if (strncmp(fs->vfs_info.name, name,
+		    sizeof(fs->vfs_info.name)) == 0) { 
 			handle = fs->fs_handle;
 			break;
