summaryrefslogtreecommitdiff
path: root/usr.bin/tmux/cmd-load-buffer.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2009-07-30 17:46:13 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2009-07-30 17:46:13 +0000
commitd27b07596eb8de59d15e8979c24455ae8cabeb63 (patch)
treefeb78de415d6aa112d2e2d3b86b4d56cf599eff8 /usr.bin/tmux/cmd-load-buffer.c
parent8810e84fa87f186513b4bfd9a75c4a2322c01393 (diff)
Don't babysit people and let them try to load /dev/zero or (more useful)
/dev/null if they want.
Diffstat (limited to 'usr.bin/tmux/cmd-load-buffer.c')
-rw-r--r--usr.bin/tmux/cmd-load-buffer.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/usr.bin/tmux/cmd-load-buffer.c b/usr.bin/tmux/cmd-load-buffer.c
index 43bc7221b9a..f17483971b9 100644
--- a/usr.bin/tmux/cmd-load-buffer.c
+++ b/usr.bin/tmux/cmd-load-buffer.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-load-buffer.c,v 1.4 2009/07/26 12:58:44 nicm Exp $ */
+/* $OpenBSD: cmd-load-buffer.c,v 1.5 2009/07/30 17:46:12 nicm Exp $ */
/*
* Copyright (c) 2009 Tiago Cunha <me@tiagocunha.org>
@@ -60,10 +60,6 @@ cmd_load_buffer_exec(struct cmd *self, struct cmd_ctx *ctx)
ctx->error(ctx, "%s: %s", data->arg, strerror(errno));
return (-1);
}
- if (!S_ISREG(statbuf.st_mode)) {
- ctx->error(ctx, "%s: not a regular file", data->arg);
- return (-1);
- }
if ((f = fopen(data->arg, "rb")) == NULL) {
ctx->error(ctx, "%s: %s", data->arg, strerror(errno));