Use a smaller buffer when writing to USB devices (bug #617208).
This commit is contained in:
parent
ac3f59889c
commit
a59a950a1c
22
cups-usb-buffer-size.patch
Normal file
22
cups-usb-buffer-size.patch
Normal file
@ -0,0 +1,22 @@
|
||||
diff -up cups-1.4.6/backend/runloop.c.usb-buffer-size cups-1.4.6/backend/runloop.c
|
||||
--- cups-1.4.6/backend/runloop.c.usb-buffer-size 2011-01-10 15:37:56.885677732 +0000
|
||||
+++ cups-1.4.6/backend/runloop.c 2011-01-10 15:37:59.499623140 +0000
|
||||
@@ -45,7 +45,7 @@ backendDrainOutput(int print_fd, /* I -
|
||||
fd_set input; /* Input set for reading */
|
||||
ssize_t print_bytes, /* Print bytes read */
|
||||
bytes; /* Bytes written */
|
||||
- char print_buffer[8192], /* Print data buffer */
|
||||
+ char print_buffer[512], /* Print data buffer */
|
||||
*print_ptr; /* Pointer into print data buffer */
|
||||
struct timeval timeout; /* Timeout for read... */
|
||||
|
||||
@@ -160,7 +160,7 @@ backendRunLoop(
|
||||
bytes; /* Bytes written */
|
||||
int paperout; /* "Paper out" status */
|
||||
int offline; /* "Off-line" status */
|
||||
- char print_buffer[8192], /* Print data buffer */
|
||||
+ char print_buffer[512], /* Print data buffer */
|
||||
*print_ptr, /* Pointer into print data buffer */
|
||||
bc_buffer[1024]; /* Back-channel data buffer */
|
||||
struct timeval timeout; /* Timeout for select() */
|
||||
diff -up cups-1.4.6/backend/usb.c.usb-buffer-size cups-1.4.6/backend/usb.c
|
@ -67,6 +67,7 @@ Patch36: cups-ricoh-deviceid-oid.patch
|
||||
Patch37: cups-texttops-rotate-page.patch
|
||||
Patch38: cups-autotype-crash.patch
|
||||
Patch39: cups-str3754.patch
|
||||
Patch40: cups-usb-buffer-size.patch
|
||||
|
||||
Patch100: cups-lspp.patch
|
||||
|
||||
@ -276,6 +277,8 @@ module.
|
||||
%patch38 -p1 -b .autotype-crash
|
||||
# Don't crash when job queued for printer that times out (bug #660604).
|
||||
%patch39 -p1 -b .str3754
|
||||
# Use a smaller buffer when writing to USB devices (bug #617208).
|
||||
%patch40 -p1 -b .usb-buffer-size
|
||||
|
||||
%if %lspp
|
||||
# LSPP support.
|
||||
@ -574,6 +577,7 @@ rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%changelog
|
||||
* Mon Jan 10 2011 Tim Waugh <twaugh@redhat.com> 1:1.4.6-2
|
||||
- Use a smaller buffer when writing to USB devices (bug #617208).
|
||||
- Handle EAI_NONAME when resolving hostnames (bug #617208).
|
||||
|
||||
* Fri Jan 07 2011 Jiri Popelka <jpopelka@redhat.com> 1:1.4.6-1
|
||||
|
Loading…
Reference in New Issue
Block a user