-
Notifications
You must be signed in to change notification settings - Fork 469
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add 64-bit file support #541
Comments
CUPS.org User: jlovell We added large jobs support with the attached patch. Beta users have reported it works well. |
CUPS.org User: mike Hmm, just looking through the diff now - you are using a definition called PRIdMAX, which is only defined in inttypes.h and there is no fallback definition... :) I don't think this is insurmountable, just that we might do some pretty wrapping and/or embed the definition in config.h so that it is always defined... |
CUPS.org User: mike Fixed in Subversion repository. Please review my changes (only tested on Linux so far...) FWIW, your patch missed some spots (no mirroring to the old data_remaining member and you missed the "bytes" member of the client structure) and I've restructured things to support large files on more platforms (use long long instead of depending on inttypes and strtoimax). Also, I renamed the old data_remaining to _data_remaining and added some new APIs to simplify handling of 64-bit content lengths. |
"largefile.diff": RCS file: /cvs/root/cups/config.h.in,v /*
RCS file: /cvs/root/cups/backend/lpd.c,v #ifdef WIN32 include <winsock.h>@@ -221,7 +224,7 @@
@@ -547,8 +550,8 @@
+#ifndef min /*
if (http->data_remaining <= 0)
if (http->used == 0 && length <= 256) if (bytes > 0)
if (http->data_encoding == HTTP_ENCODE_CHUNKED) http->data_encoding = HTTP_ENCODE_CHUNKED;
return (http->data_remaining); Index: cups/http.hRCS file: /cvs/root/cups/cups/http.h,v
Index: cups/ipp.cRCS file: /cvs/root/cups/cups/ipp.c,v +#ifndef min
@@ -94,7 +98,8 @@
while ((bytes = httpRead(http, buffer, sizeof(buffer))) > 0)
Index: scheduler/client.cRCS file: /cvs/root/cups/scheduler/client.c,v /*
+#ifndef min
|
Version: 1.2-feature
CUPS.org User: mike
Please add support for large files (64-bit file ops, >2GB, etc.) for all programs and libs.
The text was updated successfully, but these errors were encountered: