Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Print a warning and require confirmation prior to continuing with a commit after detection of time skew. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
c6a65cbd8176ab1fba402708064bc702 |
| User & Date: | drh 2010-09-29 15:49:29.000 |
Context
|
2010-09-29
| ||
| 16:58 | Avoid duplicate "/" in the redirect from the /home webpage. ... (check-in: cabf810b0b user: drh tags: trunk) | |
| 16:01 | merged trunk ... (check-in: e2db682fa0 user: wolfgang tags: wolfgangFormat2CSS_2) | |
| 15:49 | Print a warning and require confirmation prior to continuing with a commit after detection of time skew. ... (check-in: c6a65cbd81 user: drh tags: trunk) | |
| 15:20 | Sync opertions warn about clock skew between client and server. ... (check-in: 71c40d3bdb user: drh tags: trunk) | |
Changes
Changes to src/checkin.c.
| ︙ | ︙ | |||
642 643 644 645 646 647 648 649 650 651 652 653 654 655 |
/*
** Autosync if autosync is enabled and this is not a private check-in.
*/
if( !g.markPrivate ){
autosync(AUTOSYNC_PULL);
}
/* There are two ways this command may be executed. If there are
** no arguments following the word "commit", then all modified files
** in the checked out directory are committed. If one or more arguments
** follows "commit", then only those files are committed.
**
** After the following function call has returned, the Global.aCommitFile[]
| > > > > > > > > > > > > | 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 |
/*
** Autosync if autosync is enabled and this is not a private check-in.
*/
if( !g.markPrivate ){
autosync(AUTOSYNC_PULL);
}
/* Require confirmation to continue with the check-in if there is
** clock skew
*/
if( g.clockSkewSeen ){
Blob ans;
blob_zero(&ans);
prompt_user("continue in spite of time skew (y/N)? ", &ans);
if( blob_str(&ans)[0]!='y' ){
fossil_exit(1);
}
}
/* There are two ways this command may be executed. If there are
** no arguments following the word "commit", then all modified files
** in the checked out directory are committed. If one or more arguments
** follows "commit", then only those files are committed.
**
** After the following function call has returned, the Global.aCommitFile[]
|
| ︙ | ︙ |
Changes to src/main.c.
| ︙ | ︙ | |||
81 82 83 84 85 86 87 88 89 90 91 92 93 94 | 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 */ int *aCommitFile; /* Array of files to be committed */ int markPrivate; /* All new artifacts are private if true */ int urlIsFile; /* True if a "file:" url */ int urlIsHttps; /* True if a "https:" url */ int urlIsSsh; /* True if an "ssh:" url */ char *urlName; /* Hostname for http: or filename for file: */ char *urlHostname; /* The HOST: parameter on http headers */ char *urlProtocol; /* "http" or "https" */ | > | 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | 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 */ int *aCommitFile; /* Array of files to be committed */ int markPrivate; /* All new artifacts are private if true */ int clockSkewSeen; /* True if clocks on client and server out of sync */ int urlIsFile; /* True if a "file:" url */ int urlIsHttps; /* True if a "https:" url */ int urlIsSsh; /* True if an "ssh:" url */ char *urlName; /* Hostname for http: or filename for file: */ char *urlHostname; /* The HOST: parameter on http headers */ char *urlProtocol; /* "http" or "https" */ |
| ︙ | ︙ |
Changes to src/xfer.c.
| ︙ | ︙ | |||
1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 |
rDiff = db_double(9e99, "SELECT julianday('%q') - julianday('now')",
zTime);
if( rDiff<0.0 ) rDiff = -rDiff;
if( rDiff>9e98 ) rDiff = 0.0;
if( (rDiff*24.0*3600.0)>=60.0 ){
fossil_warning("*** time skew *** server time differs by %s",
db_timespan_name(rDiff));
}
}
continue;
}
xfer.nToken = blob_tokenize(&xfer.line, xfer.aToken, count(xfer.aToken));
nCardRcvd++;
if( !g.cgiOutput && !g.fQuiet ){
| > | 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 |
rDiff = db_double(9e99, "SELECT julianday('%q') - julianday('now')",
zTime);
if( rDiff<0.0 ) rDiff = -rDiff;
if( rDiff>9e98 ) rDiff = 0.0;
if( (rDiff*24.0*3600.0)>=60.0 ){
fossil_warning("*** time skew *** server time differs by %s",
db_timespan_name(rDiff));
g.clockSkewSeen = 1;
}
}
continue;
}
xfer.nToken = blob_tokenize(&xfer.line, xfer.aToken, count(xfer.aToken));
nCardRcvd++;
if( !g.cgiOutput && !g.fQuiet ){
|
| ︙ | ︙ |