diff options
author | Bin Meng <bin.meng@windriver.com> | 2022-08-24 17:39:40 +0800 |
---|---|---|
committer | Thomas Huth <thuth@redhat.com> | 2022-08-25 15:16:13 +0200 |
commit | 3c239aa77ed19521992a0b14594907adc0d79a6c (patch) | |
tree | e798c032e6bb092cbd61d3e9b810dab725a45b94 /tests/qtest/qmp-test.c | |
parent | a47ea61de593a8243a66caba9d436040ecae25d5 (diff) | |
download | qemu-3c239aa77ed19521992a0b14594907adc0d79a6c.zip qemu-3c239aa77ed19521992a0b14594907adc0d79a6c.tar.gz qemu-3c239aa77ed19521992a0b14594907adc0d79a6c.tar.bz2 |
tests/qtest: Use g_mkdtemp()
Windows does not provide a mkdtemp() API, but glib does.
Replace mkdtemp() call with the glib version.
Signed-off-by: Bin Meng <bin.meng@windriver.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20220824094029.1634519-3-bmeng.cn@gmail.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'tests/qtest/qmp-test.c')
-rw-r--r-- | tests/qtest/qmp-test.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/qtest/qmp-test.c b/tests/qtest/qmp-test.c index 9a42480..bf7304c 100644 --- a/tests/qtest/qmp-test.c +++ b/tests/qtest/qmp-test.c @@ -166,8 +166,8 @@ char *fifo_name; static void setup_blocking_cmd(void) { - if (!mkdtemp(tmpdir)) { - g_error("mkdtemp: %s", strerror(errno)); + if (!g_mkdtemp(tmpdir)) { + g_error("g_mkdtemp: %s", strerror(errno)); } fifo_name = g_strdup_printf("%s/fifo", tmpdir); if (mkfifo(fifo_name, 0666)) { |