From: root Date: Wed, 28 May 2008 15:28:41 +0000 (-0400) Subject: When copying a directory, be sure the destination directory is in place first X-Git-Tag: 0.1.0~58 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a85a1f35d9bb3d3dd75d5f05593abdd1273129b8;p=thirdparty%2Fplymouth.git When copying a directory, be sure the destination directory is in place first --- diff --git a/src/libply/ply-utils.c b/src/libply/ply-utils.c index 910b5712..8c68a165 100644 --- a/src/libply/ply-utils.c +++ b/src/libply/ply-utils.c @@ -927,6 +927,9 @@ ply_copy_directory (const char *source, if (dir == NULL) return false; + if (!ply_create_directory (destination)) + return false; + while ((entry = readdir (dir)) != NULL) { if (strcmp (entry->d_name, ".") == 0)