diff options
-rw-r--r-- | xkb/ddxList.c | 3 | ||||
-rw-r--r-- | xkb/ddxLoad.c | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/xkb/ddxList.c b/xkb/ddxList.c index ea356954c..85dd0501b 100644 --- a/xkb/ddxList.c +++ b/xkb/ddxList.c @@ -235,6 +235,9 @@ int rval; buf = malloc(PATH_MAX * sizeof(char)); if (!buf) { fclose(in); +#if defined(WIN32) || defined(__CYGWIN__) + unlink(tmpname); +#endif return BadAlloc; } while ((status==Success)&&((tmp=fgets(buf,PATH_MAX,in))!=NULL)) { diff --git a/xkb/ddxLoad.c b/xkb/ddxLoad.c index 77a5d9555..ca42f93ab 100644 --- a/xkb/ddxLoad.c +++ b/xkb/ddxLoad.c @@ -278,6 +278,10 @@ XkbDDXCompileKeymapByNames( XkbDescPtr xkb, nameRtrn[nameRtrnLen-1]= '\0'; } free(buf); +#if defined(WIN32) || defined(__CYGWIN__) + /* remove the temporary file */ + unlink(tmpname); +#endif return TRUE; } else |