Fossil SCM

Fix for _popen and _pclose with Visual C++ in the new export.c module.

wyoung 2019-03-17 10:44 trunk
Commit 931da0c3e37913ea382b8ce7cca9057a6a20c741cb7ca0d04432c5ce5429923b
1 file changed +7
--- src/export.c
+++ src/export.c
@@ -37,10 +37,17 @@
3737
char *name; /* Name of the mark. Also starts with ":" */
3838
int rid; /* Corresponding object in the BLOB table */
3939
char uuid[65]; /* The GIT hash name for this object */
4040
};
4141
#endif
42
+
43
+#if defined(_WIN32) || defined(WIN32)
44
+# undef popen
45
+# define popen _popen
46
+# undef pclose
47
+# define pclose _pclose
48
+#endif
4249
4350
/*
4451
** Output a "committer" record for the given user.
4552
** NOTE: the given user name may be an email itself.
4653
*/
4754
--- src/export.c
+++ src/export.c
@@ -37,10 +37,17 @@
37 char *name; /* Name of the mark. Also starts with ":" */
38 int rid; /* Corresponding object in the BLOB table */
39 char uuid[65]; /* The GIT hash name for this object */
40 };
41 #endif
 
 
 
 
 
 
 
42
43 /*
44 ** Output a "committer" record for the given user.
45 ** NOTE: the given user name may be an email itself.
46 */
47
--- src/export.c
+++ src/export.c
@@ -37,10 +37,17 @@
37 char *name; /* Name of the mark. Also starts with ":" */
38 int rid; /* Corresponding object in the BLOB table */
39 char uuid[65]; /* The GIT hash name for this object */
40 };
41 #endif
42
43 #if defined(_WIN32) || defined(WIN32)
44 # undef popen
45 # define popen _popen
46 # undef pclose
47 # define pclose _pclose
48 #endif
49
50 /*
51 ** Output a "committer" record for the given user.
52 ** NOTE: the given user name may be an email itself.
53 */
54

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button