6600438bbd
OBS-URL: https://build.opensuse.org/package/show/Archiving/cpio?expand=0&rev=ec6713ec3ebe5e0f61b02764b7cf96a9
41 lines
1.4 KiB
Diff
41 lines
1.4 KiB
Diff
Index: src/mt.c
|
|
===================================================================
|
|
--- src/mt.c.orig
|
|
+++ src/mt.c
|
|
@@ -723,11 +723,11 @@ main (int argc, char **argv)
|
|
#ifdef MTDATCOMP
|
|
case MTDATCOMP:
|
|
#endif
|
|
- tapedesc = rmtopen (tapedev, O_WRONLY, 0, rsh_command_option);
|
|
+ tapedesc = rmtopen (tapedev, O_WRONLY | O_NONBLOCK, 0, rsh_command_option);
|
|
break;
|
|
|
|
default:
|
|
- tapedesc = rmtopen (tapedev, O_RDONLY, 0, rsh_command_option);
|
|
+ tapedesc = rmtopen (tapedev, O_RDONLY | O_NONBLOCK, 0, rsh_command_option);
|
|
}
|
|
|
|
if (tapedesc == -1)
|
|
Index: src/util.c
|
|
===================================================================
|
|
--- src/util.c.orig
|
|
+++ src/util.c
|
|
@@ -767,14 +767,14 @@ open_archive (char *file)
|
|
copy_in = process_copy_in;
|
|
|
|
if (copy_function == copy_in)
|
|
- fd = rmtopen (file, O_RDONLY | O_BINARY, MODE_RW, rsh_command_option);
|
|
+ fd = rmtopen (file, O_RDONLY | O_BINARY | O_NONBLOCK, MODE_RW, rsh_command_option);
|
|
else
|
|
{
|
|
if (!append_flag)
|
|
- fd = rmtopen (file, O_WRONLY | O_CREAT | O_TRUNC | O_BINARY, MODE_RW,
|
|
+ fd = rmtopen (file, O_WRONLY | O_CREAT | O_TRUNC | O_BINARY | O_NONBLOCK, MODE_RW,
|
|
rsh_command_option);
|
|
else
|
|
- fd = rmtopen (file, O_RDWR | O_BINARY, MODE_RW, rsh_command_option);
|
|
+ fd = rmtopen (file, O_RDWR | O_BINARY | O_NONBLOCK, MODE_RW, rsh_command_option);
|
|
}
|
|
|
|
return fd;
|