search for: filename_to_free

Displaying 4 results from an estimated 4 matches for "filename_to_free".

2014 Jun 23
2
[PATCH] edit: add -m option
...down (g) == -1) @@ -304,6 +323,15 @@ edit_files (int argc, char *argv[]) } static void +edit_files_simple (int argc, char *argv[]) +{ + int i; + + for (i = 0; i < argc; ++i) + edit (argv[i], NULL); +} + +static void edit (const char *filename, const char *root) { CLEANUP_FREE char *filename_to_free = NULL; @@ -318,7 +346,7 @@ edit (const char *filename, const char *root) CLEANUP_FREE char *backupname = NULL; /* Windows? Special handling is required. */ - if (is_windows (g, root)) + if (root != NULL && is_windows (g, root)) filename = filename_to_free = windows_path (g,...
2014 Aug 28
14
[PATCH 00/13] code refactorings for tools
Hi, this series does a couple of code reorganizations/refactoring in code used by tools: the windows path handling code, and the two types of file editing (using editor, and using perl expression). There's still a code duplication between the two variants of file editing, but it is just within a single source, and can be easily solved now (planning as next step). Pino Toscano (13): edit:
2014 Jun 23
2
Re: [PATCH] edit: add -m option
On Mon, Jun 23, 2014 at 12:30:07PM +0100, Richard W.M. Jones wrote: > > Same comment about do_edit_simple as I previously posted about > do_cat_simple. I mean edit_files_simple ... Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows
2014 Jun 23
2
Re: [PATCH] cat: add -m option
On Monday 23 June 2014 12:29:07 Richard W.M. Jones wrote: > On Mon, Jun 23, 2014 at 01:00:11PM +0200, Pino Toscano wrote: > > static int > > > > +do_cat_simple (int argc, char *argv[]) > > +{ > > + unsigned errors = 0; > > + int i; > > + > > + for (i = 0; i < argc; ++i) { > > + if (guestfs_download (g, argv[i],