Fossil SCM
For SSH URLs don't explicitly kill SSH with SIGINT, but let close kill process. Observed as a "Killed by signal 2." error on FreeBSD.
Commit
0e8f0bc3170d761662988c7004bf11bc66ff376c
Parent
d8586b5670c3148…
1 file changed
+1
-2
+1
-2
| --- src/popen.c | ||
| +++ src/popen.c | ||
| @@ -204,19 +204,18 @@ | ||
| 204 | 204 | #endif |
| 205 | 205 | } |
| 206 | 206 | |
| 207 | 207 | /* |
| 208 | 208 | ** Close the connection to a child process previously created using |
| 209 | -** popen2(). Kill off the child process, then close the pipes. | |
| 209 | +** popen2(). | |
| 210 | 210 | */ |
| 211 | 211 | void pclose2(int fdIn, FILE *pOut, int childPid){ |
| 212 | 212 | #ifdef _WIN32 |
| 213 | 213 | /* Not implemented, yet */ |
| 214 | 214 | close(fdIn); |
| 215 | 215 | fclose(pOut); |
| 216 | 216 | #else |
| 217 | 217 | close(fdIn); |
| 218 | 218 | fclose(pOut); |
| 219 | - kill(childPid, SIGINT); | |
| 220 | 219 | while( waitpid(0, 0, WNOHANG)>0 ) {} |
| 221 | 220 | #endif |
| 222 | 221 | } |
| 223 | 222 |
| --- src/popen.c | |
| +++ src/popen.c | |
| @@ -204,19 +204,18 @@ | |
| 204 | #endif |
| 205 | } |
| 206 | |
| 207 | /* |
| 208 | ** Close the connection to a child process previously created using |
| 209 | ** popen2(). Kill off the child process, then close the pipes. |
| 210 | */ |
| 211 | void pclose2(int fdIn, FILE *pOut, int childPid){ |
| 212 | #ifdef _WIN32 |
| 213 | /* Not implemented, yet */ |
| 214 | close(fdIn); |
| 215 | fclose(pOut); |
| 216 | #else |
| 217 | close(fdIn); |
| 218 | fclose(pOut); |
| 219 | kill(childPid, SIGINT); |
| 220 | while( waitpid(0, 0, WNOHANG)>0 ) {} |
| 221 | #endif |
| 222 | } |
| 223 |
| --- src/popen.c | |
| +++ src/popen.c | |
| @@ -204,19 +204,18 @@ | |
| 204 | #endif |
| 205 | } |
| 206 | |
| 207 | /* |
| 208 | ** Close the connection to a child process previously created using |
| 209 | ** popen2(). |
| 210 | */ |
| 211 | void pclose2(int fdIn, FILE *pOut, int childPid){ |
| 212 | #ifdef _WIN32 |
| 213 | /* Not implemented, yet */ |
| 214 | close(fdIn); |
| 215 | fclose(pOut); |
| 216 | #else |
| 217 | close(fdIn); |
| 218 | fclose(pOut); |
| 219 | while( waitpid(0, 0, WNOHANG)>0 ) {} |
| 220 | #endif |
| 221 | } |
| 222 |