summaryrefslogtreecommitdiff
path: root/vdr.c
diff options
context:
space:
mode:
Diffstat (limited to 'vdr.c')
-rw-r--r--vdr.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/vdr.c b/vdr.c
index 9c54e3a..cdc460e 100644
--- a/vdr.c
+++ b/vdr.c
@@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
- * $Id: vdr.c 1.166 2003/08/24 11:18:04 kls Exp $
+ * $Id: vdr.c 1.168 2003/09/05 13:14:16 kls Exp $
*/
#include <getopt.h>
@@ -199,6 +199,10 @@ int main(int argc, char *argv[])
case 's': Shutdown = optarg;
break;
case 't': Terminal = optarg;
+ if (access(Terminal, R_OK | W_OK) < 0) {
+ fprintf(stderr, "vdr: can't access terminal: %s\n", Terminal);
+ return 2;
+ }
break;
case 'V': DisplayVersion = true;
break;
@@ -383,7 +387,7 @@ int main(int argc, char *argv[])
const char *msg = "no primary device found - using first device!";
fprintf(stderr, "vdr: %s\n", msg);
esyslog("ERROR: %s", msg);
- if (!cDevice::SetPrimaryDevice(0))
+ if (!cDevice::SetPrimaryDevice(1))
return 2;
if (!cDevice::PrimaryDevice()) {
const char *msg = "no primary device found - giving up!";