search for: do_mkdtemp

Displaying 3 results from an estimated 3 matches for "do_mkdtemp".

2009 Aug 11
1
[PATCH libguestfs] generator.ml: constify do_mkdtemp
...presumes a metric ton of other changes), but mostly a heads-up where I'm going. >From 62cbebffe9859046019b500e4bcdb0e44e575755 Mon Sep 17 00:00:00 2001 From: Jim Meyering <meyering at redhat.com> Date: Tue, 11 Aug 2009 17:17:08 +0200 Subject: [PATCH libguestfs] generator.ml: constify do_mkdtemp * daemon/dir.c (do_mkdtemp): Rewrite for a "const" parameter. * src/generator.ml (mkdtemp): Declare parameter to be of type Pathname. --- daemon/dir.c | 27 ++++++++------------------- src/generator.ml | 8 +++----- 2 files changed, 11 insertions(+), 24 deletions(-) diff --git...
2012 Oct 14
1
[PATCH] NEW API: mktemp
...++++++++++++++++++++++ gobject/Makefile.inc | 6 ++++-- po/POTFILES | 2 ++ src/MAX_PROC_NR | 2 +- 5 files changed, 104 insertions(+), 3 deletions(-) diff --git a/daemon/dir.c b/daemon/dir.c index aed45d6..b58cc2a 100644 --- a/daemon/dir.c +++ b/daemon/dir.c @@ -212,3 +212,64 @@ do_mkdtemp (const char *template) return r; } + +char * +do_mktemp (const char *template, + int dir, + const char *suffix) +{ + char *dest_name = NULL; + size_t suffix_len = 0; + char *r; + int err; + if (!(optargs_bitmask & GUESTFS_MKTEMP_DIR_BITMASK)) + dir = 0; + + if...
2009 Aug 12
23
[PATCH 0/23] factor and const-correctness
This started as a simple warning-elimination change. I'll get back to that series shortly ;-) It turned into a factorization and constification exercise during which I got a taste of ocaml. Thanks to Rich Jones for help with a few snippets in generator.ml. The overall result is that many previously-manually-maintained bits from daemon/*.c functions are now hoisted into the automatically-