[Pcsclite-cvs-commit] XCardII/src xcardMain.cpp,1.20,1.21

rousseau@quantz.debian.org rousseau@quantz.debian.org
Tue, 30 Sep 2003 22:22:28 +0200


Update of /cvsroot/muscleapps/XCardII/src
In directory quantz:/tmp/cvs-serv29409

Modified Files:
	xcardMain.cpp 
Log Message:
set restrictive access rights (0600) and remove temporary file
/tmp/xcard0102 just after use (this code is a great target for race
conditions but can't easily be corrected under Unix _and_ Windows)


Index: xcardMain.cpp
===================================================================
RCS file: /cvsroot/muscleapps/XCardII/src/xcardMain.cpp,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- xcardMain.cpp	5 Nov 2002 18:41:19 -0000	1.20
+++ xcardMain.cpp	30 Sep 2003 20:22:25 -0000	1.21
@@ -742,6 +742,10 @@
 			     "Could Not Launch Viewer.");
     } 
 
+#ifdef MSC_TARGET_UNIX
+    unlink(XCARD_OUTPUT_FILE);
+#endif
+
   } while (0);
 
 }
@@ -899,6 +903,10 @@
 
       break;
     }
+
+#ifdef MSC_TARGET_UNIX
+    chmod(exportFile, 0600);
+#endif
     
     rv = MSCReadAllocateObject(&pConnection, objectID, 
 			       &dataBuffer, &dataSize,