socsvn commit: r254583 - soc2013/dpl/head/contrib/xz/src/xz
dpl at FreeBSD.org
dpl at FreeBSD.org
Wed Jul 10 21:28:47 UTC 2013
Author: dpl
Date: Wed Jul 10 21:28:47 2013
New Revision: 254583
URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=254583
Log:
Start changing coder_run to handle all the files needed so that we can call cap_init() after opening everything.
Modified:
soc2013/dpl/head/contrib/xz/src/xz/coder.c
soc2013/dpl/head/contrib/xz/src/xz/coder.h
soc2013/dpl/head/contrib/xz/src/xz/main.c
Modified: soc2013/dpl/head/contrib/xz/src/xz/coder.c
==============================================================================
--- soc2013/dpl/head/contrib/xz/src/xz/coder.c Wed Jul 10 20:56:04 2013 (r254582)
+++ soc2013/dpl/head/contrib/xz/src/xz/coder.c Wed Jul 10 21:28:47 2013 (r254583)
@@ -609,8 +609,9 @@
extern void
-coder_run(const char *filename)
+coder_run(const char *filename[], int files)
{
+ file_pair all_files
// Set and possibly print the filename for the progress message.
message_filename(filename);
Modified: soc2013/dpl/head/contrib/xz/src/xz/coder.h
==============================================================================
--- soc2013/dpl/head/contrib/xz/src/xz/coder.h Wed Jul 10 20:56:04 2013 (r254582)
+++ soc2013/dpl/head/contrib/xz/src/xz/coder.h Wed Jul 10 21:28:47 2013 (r254583)
@@ -58,4 +58,4 @@
extern void coder_set_compression_settings(void);
/// Compress or decompress the given file
-extern void coder_run(const char *filename);
+extern void coder_run(const char *filename[], int files);
Modified: soc2013/dpl/head/contrib/xz/src/xz/main.c
==============================================================================
--- soc2013/dpl/head/contrib/xz/src/xz/main.c Wed Jul 10 20:56:04 2013 (r254582)
+++ soc2013/dpl/head/contrib/xz/src/xz/main.c Wed Jul 10 21:28:47 2013 (r254583)
@@ -142,6 +142,8 @@
int
main(int argc, char **argv)
{
+ int files = 0;
+
#if defined(_WIN32) && !defined(__CYGWIN__)
InitializeCriticalSection(&exit_status_cs);
#endif
@@ -241,11 +243,10 @@
// string and the code still knows that it is
// handling the special case of stdin.
args.arg_names[i] = (char *)stdin_filename;
+ files++;
}
}
-
- // Do the actual compression or decompression.
- run(args.arg_names);
+ run(args.arg_names, files);
// If --files or --files0 was used, process the filenames from the
// given file or stdin. Note that here we don't consider "-" to
More information about the svn-soc-all
mailing list