--- cksfv-1.3.14.orig/cksfv.1
+++ cksfv-1.3.14/cksfv.1
@@ -52,8 +52,9 @@
 .B \-f file
 Verify checksums in the sfv file
 .TP
-.B \-g path
-Go to the path name directory and verify checksums in the sfv file
+.B \-g file
+Change current directory to the path name of the file and verify checksums
+in the sfv.
 .TP
 .B \-i
 Ignore case in filenames. This is used in the checksum verification mode.
--- cksfv-1.3.14.orig/src/readsfv.c
+++ cksfv-1.3.14/src/readsfv.c
@@ -84,6 +84,18 @@
 	    fprintf(stderr, "cksfv: %s: %s\n", fn, strerror(errno));
 	return 1;
     }
+    if (fstat(fileno(fd), &st)) {
+	if (!TOTALLY_QUIET)
+	    fprintf(stderr, "cksfv: can not fstat %s: %s\n", fn, strerror(errno));
+	fclose(fd);
+	return 1;
+    }
+    if (S_ISDIR(st.st_mode)) {
+	if (!TOTALLY_QUIET)
+	    fprintf(stderr, "cksfv: %s: Is a directory\n", fn);
+	fclose(fd);
+	return 1;
+    }
 
     if (chdir(dir) != 0) {
 	if (!TOTALLY_QUIET)

