Advertisement
Guest User

Untitled

a guest
Jul 29th, 2017
446
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 1.85 KB | None | 0 0
  1. From c14eefb0e728c8504635efa5aafdd778a0cf4536 Mon Sep 17 00:00:00 2001
  2. From: Denis Dzyubenko <denis.dzyubenko@nokia.com>
  3. Date: Tue, 1 Mar 2011 12:05:47 +0100
  4. Subject: [PATCH] QLocale: create temp files one the same device so that rename() will work properly
  5.  
  6. ---
  7. util/local_database/qlocalexml2cpp.py |    6 +++---
  8.  1 files changed, 3 insertions(+), 3 deletions(-)
  9.  
  10. diff --git a/util/local_database/qlocalexml2cpp.py b/util/local_database/qlocalexml2cpp.py
  11. index 4929ef6..ab3f1da 100755
  12. --- a/util/local_database/qlocalexml2cpp.py
  13. +++ b/util/local_database/qlocalexml2cpp.py
  14. @@ -448,7 +448,7 @@ def main():
  15.      if not os.path.isfile(qtsrcdir + "/src/corelib/tools/qlocale.qdoc"):
  16.          usage()
  17.  
  18. -    (data_temp_file, data_temp_file_path) = tempfile.mkstemp("qlocale_data_p")
  19. +    (data_temp_file, data_temp_file_path) = tempfile.mkstemp("qlocale_data_p", dir=qtsrcdir)
  20.      data_temp_file = os.fdopen(data_temp_file, "w")
  21.      qlocaledata_file = open(qtsrcdir + "/src/corelib/tools/qlocale_data_p.h", "r")
  22.      s = qlocaledata_file.readline()
  23. @@ -766,7 +766,7 @@ def main():
  24.  
  25.      # qlocale.h
  26.  
  27. -    (qlocaleh_temp_file, qlocaleh_temp_file_path) = tempfile.mkstemp("qlocale.h")
  28. +    (qlocaleh_temp_file, qlocaleh_temp_file_path) = tempfile.mkstemp("qlocale.h", dir=qtsrcdir)
  29.      qlocaleh_temp_file = os.fdopen(qlocaleh_temp_file, "w")
  30.      qlocaleh_file = open(qtsrcdir + "/src/corelib/tools/qlocale.h", "r")
  31.      s = qlocaleh_file.readline()
  32. @@ -825,7 +825,7 @@ def main():
  33.  
  34.      # qlocale.qdoc
  35.  
  36. -    (qlocaleqdoc_temp_file, qlocaleqdoc_temp_file_path) = tempfile.mkstemp("qlocale.qdoc")
  37. +    (qlocaleqdoc_temp_file, qlocaleqdoc_temp_file_path) = tempfile.mkstemp("qlocale.qdoc", dir=qtsrcdir)
  38.      qlocaleqdoc_temp_file = os.fdopen(qlocaleqdoc_temp_file, "w")
  39.      qlocaleqdoc_file = open(qtsrcdir + "/src/corelib/tools/qlocale.qdoc", "r")
  40.      s = qlocaleqdoc_file.readline()
  41. --
  42. 1.7.1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement