Index: uspace/lib/c/generic/devman.c
===================================================================
--- uspace/lib/c/generic/devman.c	(revision 55054db039128bfac2967c382b30c62139248672)
+++ uspace/lib/c/generic/devman.c	(revision 852803acec74881c592308b12f0bbffdb890eafa)
@@ -415,9 +415,15 @@
 	}
 
+	/* To be on the safe-side. */
 	path[path_size - 1] = 0;
 
-	if (IPC_GET_ARG2(data_request_call) >= path_size) {
+	size_t transferred_size = IPC_GET_ARG2(data_request_call);
+
+	if (transferred_size >= path_size) {
 		return ELIMIT;
 	}
+
+	/* Terminate the string (trailing 0 not send over IPC). */
+	path[transferred_size] = 0;
 
 	return EOK;
