Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | The server now issues error messages in the synchronization protocol when a database error occurs during sync. Ticket [39f3294e213111a51e93d02fef6faa0062979619] |
|---|---|
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
2be82dcc2aba6fdcb5fed4ca4eebaf21 |
| User & Date: | drh 2008-12-07 18:48:09.000 |
References
|
2008-12-07
| ||
| 18:50 | • Fixed ticket [39f3294e21]: make fossil recognize cgi errors from remote repository plus 2 other changes artifact: 0bd9b28457 user: drh | |
Context
|
2008-12-09
| ||
| 20:25 | Change the add command CLI doc to reflect recursive add of directories. check-in: 83447b7bf1 user: kejoki tags: trunk | |
|
2008-12-07
| ||
| 18:48 | The server now issues error messages in the synchronization protocol when a database error occurs during sync. Ticket [39f3294e213111a51e93d02fef6faa0062979619] check-in: 2be82dcc2a user: drh tags: trunk | |
| 18:11 | Enhance the "fossil add" command so that when a directory is named, all contents of that directory are added recursively. Ticket [e02ffabcdaaaf606099ac09227833ba282fdaace] check-in: 8c4e72e223 user: drh tags: trunk | |
Changes
Changes to src/db.c.
| ︙ | ︙ | |||
64 65 66 67 68 69 70 71 72 73 74 75 76 77 |
*/
static void db_err(const char *zFormat, ...){
va_list ap;
char *z;
va_start(ap, zFormat);
z = vmprintf(zFormat, ap);
va_end(ap);
if( g.cgiPanic ){
g.cgiPanic = 0;
cgi_printf("<h1>Database Error</h1>\n"
"<pre>%h</pre>", z);
cgi_reply();
}else{
fprintf(stderr, "%s: %s\n", g.argv[0], z);
| > > > > > | 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 |
*/
static void db_err(const char *zFormat, ...){
va_list ap;
char *z;
va_start(ap, zFormat);
z = vmprintf(zFormat, ap);
va_end(ap);
if( g.xferPanic ){
cgi_reset_content();
@ error Database\serror:\s%F(z)
cgi_reply();
}
if( g.cgiPanic ){
g.cgiPanic = 0;
cgi_printf("<h1>Database Error</h1>\n"
"<pre>%h</pre>", z);
cgi_reply();
}else{
fprintf(stderr, "%s: %s\n", g.argv[0], z);
|
| ︙ | ︙ |
Changes to src/main.c.
| ︙ | ︙ | |||
70 71 72 73 74 75 76 77 78 79 80 81 82 83 | char *zBaseURL; /* Full text of the URL being served */ char *zTop; /* Parent directory of zPath */ const char *zContentType; /* The content type of the input HTTP request */ int iErrPriority; /* Priority of current error message */ char *zErrMsg; /* Text of an error message */ Blob cgiIn; /* Input to an xfer www method */ int cgiPanic; /* Write error messages to CGI */ int fullHttpReply; /* True for full HTTP reply. False for CGI reply */ Th_Interp *interp; /* The TH1 interpreter */ FILE *httpIn; /* Accept HTTP input from here */ FILE *httpOut; /* Send HTTP output here */ int xlinkClusterOnly; /* Set when cloning. Only process clusters */ int fTimeFormat; /* 1 for UTC. 2 for localtime. 0 not yet selected */ | > | 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | char *zBaseURL; /* Full text of the URL being served */ char *zTop; /* Parent directory of zPath */ const char *zContentType; /* The content type of the input HTTP request */ int iErrPriority; /* Priority of current error message */ char *zErrMsg; /* Text of an error message */ Blob cgiIn; /* Input to an xfer www method */ int cgiPanic; /* Write error messages to CGI */ int xferPanic; /* Write error messages in XFER protocol */ int fullHttpReply; /* True for full HTTP reply. False for CGI reply */ Th_Interp *interp; /* The TH1 interpreter */ FILE *httpIn; /* Accept HTTP input from here */ FILE *httpOut; /* Send HTTP output here */ int xlinkClusterOnly; /* Set when cloning. Only process clusters */ int fTimeFormat; /* 1 for UTC. 2 for localtime. 0 not yet selected */ |
| ︙ | ︙ |
Changes to src/xfer.c.
| ︙ | ︙ | |||
537 538 539 540 541 542 543 544 545 546 547 548 549 550 |
memset(&xfer, 0, sizeof(xfer));
blobarray_zero(xfer.aToken, count(xfer.aToken));
cgi_set_content_type(g.zContentType);
blob_zero(&xfer.err);
xfer.pIn = &g.cgiIn;
xfer.pOut = cgi_output_blob();
xfer.mxSend = db_get_int("max-download", 5000000);
db_begin_transaction();
db_multi_exec(
"CREATE TEMP TABLE onremote(rid INTEGER PRIMARY KEY);"
);
while( blob_line(xfer.pIn, &xfer.line) ){
if( blob_buffer(&xfer.line)[0]=='#' ) continue;
| > | 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 |
memset(&xfer, 0, sizeof(xfer));
blobarray_zero(xfer.aToken, count(xfer.aToken));
cgi_set_content_type(g.zContentType);
blob_zero(&xfer.err);
xfer.pIn = &g.cgiIn;
xfer.pOut = cgi_output_blob();
xfer.mxSend = db_get_int("max-download", 5000000);
g.xferPanic = 1;
db_begin_transaction();
db_multi_exec(
"CREATE TEMP TABLE onremote(rid INTEGER PRIMARY KEY);"
);
while( blob_line(xfer.pIn, &xfer.line) ){
if( blob_buffer(&xfer.line)[0]=='#' ) continue;
|
| ︙ | ︙ |