Fossil SCM

merged in [336e1355b927f].

stephan 2012-08-03 18:41 UTC th1-query-api merge
Commit 82e78034dad73cb747fcd422705820b7f0a2345c
-3
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438438
}else if( whence==BLOB_SEEK_CUR ){
439439
p->iCursor += offset;
440440
}else if( whence==BLOB_SEEK_END ){
441441
p->iCursor = p->nUsed + offset - 1;
442442
}
443
- if( p->iCursor<0 ){
444
- p->iCursor = 0;
445
- }
446443
if( p->iCursor>p->nUsed ){
447444
p->iCursor = p->nUsed;
448445
}
449446
return p->iCursor;
450447
}
451448
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438 }else if( whence==BLOB_SEEK_CUR ){
439 p->iCursor += offset;
440 }else if( whence==BLOB_SEEK_END ){
441 p->iCursor = p->nUsed + offset - 1;
442 }
443 if( p->iCursor<0 ){
444 p->iCursor = 0;
445 }
446 if( p->iCursor>p->nUsed ){
447 p->iCursor = p->nUsed;
448 }
449 return p->iCursor;
450 }
451
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438 }else if( whence==BLOB_SEEK_CUR ){
439 p->iCursor += offset;
440 }else if( whence==BLOB_SEEK_END ){
441 p->iCursor = p->nUsed + offset - 1;
442 }
 
 
 
443 if( p->iCursor>p->nUsed ){
444 p->iCursor = p->nUsed;
445 }
446 return p->iCursor;
447 }
448
-3
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438438
}else if( whence==BLOB_SEEK_CUR ){
439439
p->iCursor += offset;
440440
}else if( whence==BLOB_SEEK_END ){
441441
p->iCursor = p->nUsed + offset - 1;
442442
}
443
- if( p->iCursor<0 ){
444
- p->iCursor = 0;
445
- }
446443
if( p->iCursor>p->nUsed ){
447444
p->iCursor = p->nUsed;
448445
}
449446
return p->iCursor;
450447
}
451448
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438 }else if( whence==BLOB_SEEK_CUR ){
439 p->iCursor += offset;
440 }else if( whence==BLOB_SEEK_END ){
441 p->iCursor = p->nUsed + offset - 1;
442 }
443 if( p->iCursor<0 ){
444 p->iCursor = 0;
445 }
446 if( p->iCursor>p->nUsed ){
447 p->iCursor = p->nUsed;
448 }
449 return p->iCursor;
450 }
451
--- src/blob.c
+++ src/blob.c
@@ -438,13 +438,10 @@
438 }else if( whence==BLOB_SEEK_CUR ){
439 p->iCursor += offset;
440 }else if( whence==BLOB_SEEK_END ){
441 p->iCursor = p->nUsed + offset - 1;
442 }
 
 
 
443 if( p->iCursor>p->nUsed ){
444 p->iCursor = p->nUsed;
445 }
446 return p->iCursor;
447 }
448
+27 -13
--- src/info.c
+++ src/info.c
@@ -1691,17 +1691,17 @@
16911691
int stdClrFound = 0;
16921692
int i;
16931693
16941694
@ <table border="0" cellpadding="0" cellspacing="1">
16951695
if( zIdPropagate ){
1696
- @ <tr><td colspan="6" align="left">
1696
+ @ <tr><td colspan="6" align="left"><label>
16971697
if( fPropagate ){
16981698
@ <input type="checkbox" name="%s(zIdPropagate)" checked="checked" />
16991699
}else{
17001700
@ <input type="checkbox" name="%s(zIdPropagate)" />
17011701
}
1702
- @ Propagate color to descendants</td></tr>
1702
+ @ Propagate color to descendants</label></td></tr>
17031703
}
17041704
@ <tr>
17051705
for(i=0; i<nColor; i++){
17061706
const char *zClr = aColor[i].zColor;
17071707
if( zClr==0 ) zClr = aColor[i].zCName;
@@ -1797,10 +1797,11 @@
17971797
const char *zNewBrFlag;
17981798
const char *zNewBranch;
17991799
const char *zCloseFlag;
18001800
int fPropagateColor; /* True if color propagates before edit */
18011801
int fNewPropagateColor; /* True if color propagates after edit */
1802
+ const char *zChngTime = 0; /* Value of chngtime= query param, if any */
18021803
char *zUuid;
18031804
Blob comment;
18041805
Stmt q;
18051806
18061807
login_check_credentials();
@@ -1811,10 +1812,11 @@
18111812
" FROM event WHERE objid=%d", rid);
18121813
if( zComment==0 ) fossil_redirect_home();
18131814
if( P("cancel") ){
18141815
cgi_redirectf("ci?name=%s", zUuid);
18151816
}
1817
+ if( g.perm.Setup ) zChngTime = P("chngtime");
18161818
zNewComment = PD("c",zComment);
18171819
zUser = db_text(0, "SELECT coalesce(euser,user)"
18181820
" FROM event WHERE objid=%d", rid);
18191821
if( zUser==0 ) fossil_redirect_home();
18201822
zNewUser = PDT("u",zUser);
@@ -1842,11 +1844,11 @@
18421844
char *zNow;
18431845
int nChng = 0;
18441846
18451847
login_verify_csrf_secret();
18461848
blob_zero(&ctrl);
1847
- zNow = date_in_standard_format("now");
1849
+ zNow = date_in_standard_format(zChngTime ? zChngTime : "now");
18481850
blob_appendf(&ctrl, "D %s\n", zNow);
18491851
db_multi_exec("CREATE TEMP TABLE newtags(tag UNIQUE, prefix, value)");
18501852
if( zNewColor[0]
18511853
&& (fPropagateColor!=fNewPropagateColor
18521854
|| fossil_strcmp(zColor,zNewColor)!=0)
@@ -1968,10 +1970,14 @@
19681970
}
19691971
db_finalize(&q);
19701972
blob_appendf(&suffix, ")");
19711973
@ %s(blob_str(&suffix))
19721974
@ </td></tr></table>
1975
+ if( zChngTime ){
1976
+ @ <p>The timestamp on the tag used to make the changes above
1977
+ @ will be overridden as: %s(date_in_standard_format(zChngTime))</p>
1978
+ }
19731979
@ </blockquote>
19741980
@ <hr />
19751981
blob_reset(&suffix);
19761982
}
19771983
@ <p>Make changes to attributes of check-in
@@ -1993,20 +1999,27 @@
19931999
19942000
@ <tr><td align="right" valign="top"><b>Check-in Time:</b></td>
19952001
@ <td valign="top">
19962002
@ <input type="text" name="dt" size="20" value="%h(zNewDate)" />
19972003
@ </td></tr>
2004
+
2005
+ if( zChngTime ){
2006
+ @ <tr><td align="right" valign="top"><b>Timestamp of this change:</b></td>
2007
+ @ <td valign="top">
2008
+ @ <input type="text" name="chngtime" size="20" value="%h(zChngTime)" />
2009
+ @ </td></tr>
2010
+ }
19982011
19992012
@ <tr><td align="right" valign="top"><b>Background Color:</b></td>
20002013
@ <td valign="top">
20012014
render_color_chooser(fNewPropagateColor, zNewColor, "pclr", "clr", "clrcust");
20022015
@ </td></tr>
20032016
20042017
@ <tr><td align="right" valign="top"><b>Tags:</b></td>
20052018
@ <td valign="top">
2006
- @ <input type="checkbox" id="newtag" name="newtag"%s(zNewTagFlag) />
2007
- @ Add the following new tag name to this check-in:
2019
+ @ <label><input type="checkbox" id="newtag" name="newtag"%s(zNewTagFlag) />
2020
+ @ Add the following new tag name to this check-in:</label>
20082021
@ <input type="text" style="width:15;" name="tagname" value="%h(zNewTag)"
20092022
@ onkeyup="gebi('newtag').checked=!!this.value" />
20102023
db_prepare(&q,
20112024
"SELECT tag.tagid, tagname FROM tagxref, tag"
20122025
" WHERE tagxref.rid=%d AND tagtype>0 AND tagxref.tagid=tag.tagid"
@@ -2017,28 +2030,29 @@
20172030
while( db_step(&q)==SQLITE_ROW ){
20182031
int tagid = db_column_int(&q, 0);
20192032
const char *zTagName = db_column_text(&q, 1);
20202033
char zLabel[30];
20212034
sqlite3_snprintf(sizeof(zLabel), zLabel, "c%d", tagid);
2035
+ @ <br /><label>
20222036
if( P(zLabel) ){
2023
- @ <br /><input type="checkbox" name="c%d(tagid)" checked="checked" />
2037
+ @ <input type="checkbox" name="c%d(tagid)" checked="checked" />
20242038
}else{
2025
- @ <br /><input type="checkbox" name="c%d(tagid)" />
2039
+ @ <input type="checkbox" name="c%d(tagid)" />
20262040
}
20272041
if( strncmp(zTagName, "sym-", 4)==0 ){
2028
- @ Cancel tag <b>%h(&zTagName[4])</b>
2042
+ @ Cancel tag <b>%h(&zTagName[4])</b></label>
20292043
}else{
2030
- @ Cancel special tag <b>%h(zTagName)</b>
2044
+ @ Cancel special tag <b>%h(zTagName)</b></label>
20312045
}
20322046
}
20332047
db_finalize(&q);
20342048
@ </td></tr>
20352049
20362050
@ <tr><td align="right" valign="top"><b>Branching:</b></td>
20372051
@ <td valign="top">
2038
- @ <input id="newbr" type="checkbox" name="newbr"%s(zNewBrFlag) />
2039
- @ Make this check-in the start of a new branch named:
2052
+ @ <label><input id="newbr" type="checkbox" name="newbr"%s(zNewBrFlag) />
2053
+ @ Make this check-in the start of a new branch named:</label>
20402054
@ <input type="text" style="width:15;" name="brname" value="%h(zNewBranch)"
20412055
@ onkeyup="gebi('newbr').checked=!!this.value" />
20422056
@ </td></tr>
20432057
20442058
if( is_a_leaf(rid)
@@ -2046,13 +2060,13 @@
20462060
" WHERE tagid=%d AND rid=%d AND tagtype>0",
20472061
TAG_CLOSED, rid)
20482062
){
20492063
@ <tr><td align="right" valign="top"><b>Leaf Closure:</b></td>
20502064
@ <td valign="top">
2051
- @ <input type="checkbox" name="close"%s(zCloseFlag) />
2065
+ @ <label><input type="checkbox" name="close"%s(zCloseFlag) />
20522066
@ Mark this leaf as "closed" so that it no longer appears on the
2053
- @ "leaves" page and is no longer labeled as a "<b>Leaf</b>".
2067
+ @ "leaves" page and is no longer labeled as a "<b>Leaf</b>".</label>
20542068
@ </td></tr>
20552069
}
20562070
20572071
20582072
@ <tr><td colspan="2">
20592073
--- src/info.c
+++ src/info.c
@@ -1691,17 +1691,17 @@
1691 int stdClrFound = 0;
1692 int i;
1693
1694 @ <table border="0" cellpadding="0" cellspacing="1">
1695 if( zIdPropagate ){
1696 @ <tr><td colspan="6" align="left">
1697 if( fPropagate ){
1698 @ <input type="checkbox" name="%s(zIdPropagate)" checked="checked" />
1699 }else{
1700 @ <input type="checkbox" name="%s(zIdPropagate)" />
1701 }
1702 @ Propagate color to descendants</td></tr>
1703 }
1704 @ <tr>
1705 for(i=0; i<nColor; i++){
1706 const char *zClr = aColor[i].zColor;
1707 if( zClr==0 ) zClr = aColor[i].zCName;
@@ -1797,10 +1797,11 @@
1797 const char *zNewBrFlag;
1798 const char *zNewBranch;
1799 const char *zCloseFlag;
1800 int fPropagateColor; /* True if color propagates before edit */
1801 int fNewPropagateColor; /* True if color propagates after edit */
 
1802 char *zUuid;
1803 Blob comment;
1804 Stmt q;
1805
1806 login_check_credentials();
@@ -1811,10 +1812,11 @@
1811 " FROM event WHERE objid=%d", rid);
1812 if( zComment==0 ) fossil_redirect_home();
1813 if( P("cancel") ){
1814 cgi_redirectf("ci?name=%s", zUuid);
1815 }
 
1816 zNewComment = PD("c",zComment);
1817 zUser = db_text(0, "SELECT coalesce(euser,user)"
1818 " FROM event WHERE objid=%d", rid);
1819 if( zUser==0 ) fossil_redirect_home();
1820 zNewUser = PDT("u",zUser);
@@ -1842,11 +1844,11 @@
1842 char *zNow;
1843 int nChng = 0;
1844
1845 login_verify_csrf_secret();
1846 blob_zero(&ctrl);
1847 zNow = date_in_standard_format("now");
1848 blob_appendf(&ctrl, "D %s\n", zNow);
1849 db_multi_exec("CREATE TEMP TABLE newtags(tag UNIQUE, prefix, value)");
1850 if( zNewColor[0]
1851 && (fPropagateColor!=fNewPropagateColor
1852 || fossil_strcmp(zColor,zNewColor)!=0)
@@ -1968,10 +1970,14 @@
1968 }
1969 db_finalize(&q);
1970 blob_appendf(&suffix, ")");
1971 @ %s(blob_str(&suffix))
1972 @ </td></tr></table>
 
 
 
 
1973 @ </blockquote>
1974 @ <hr />
1975 blob_reset(&suffix);
1976 }
1977 @ <p>Make changes to attributes of check-in
@@ -1993,20 +1999,27 @@
1993
1994 @ <tr><td align="right" valign="top"><b>Check-in Time:</b></td>
1995 @ <td valign="top">
1996 @ <input type="text" name="dt" size="20" value="%h(zNewDate)" />
1997 @ </td></tr>
 
 
 
 
 
 
 
1998
1999 @ <tr><td align="right" valign="top"><b>Background Color:</b></td>
2000 @ <td valign="top">
2001 render_color_chooser(fNewPropagateColor, zNewColor, "pclr", "clr", "clrcust");
2002 @ </td></tr>
2003
2004 @ <tr><td align="right" valign="top"><b>Tags:</b></td>
2005 @ <td valign="top">
2006 @ <input type="checkbox" id="newtag" name="newtag"%s(zNewTagFlag) />
2007 @ Add the following new tag name to this check-in:
2008 @ <input type="text" style="width:15;" name="tagname" value="%h(zNewTag)"
2009 @ onkeyup="gebi('newtag').checked=!!this.value" />
2010 db_prepare(&q,
2011 "SELECT tag.tagid, tagname FROM tagxref, tag"
2012 " WHERE tagxref.rid=%d AND tagtype>0 AND tagxref.tagid=tag.tagid"
@@ -2017,28 +2030,29 @@
2017 while( db_step(&q)==SQLITE_ROW ){
2018 int tagid = db_column_int(&q, 0);
2019 const char *zTagName = db_column_text(&q, 1);
2020 char zLabel[30];
2021 sqlite3_snprintf(sizeof(zLabel), zLabel, "c%d", tagid);
 
2022 if( P(zLabel) ){
2023 @ <br /><input type="checkbox" name="c%d(tagid)" checked="checked" />
2024 }else{
2025 @ <br /><input type="checkbox" name="c%d(tagid)" />
2026 }
2027 if( strncmp(zTagName, "sym-", 4)==0 ){
2028 @ Cancel tag <b>%h(&zTagName[4])</b>
2029 }else{
2030 @ Cancel special tag <b>%h(zTagName)</b>
2031 }
2032 }
2033 db_finalize(&q);
2034 @ </td></tr>
2035
2036 @ <tr><td align="right" valign="top"><b>Branching:</b></td>
2037 @ <td valign="top">
2038 @ <input id="newbr" type="checkbox" name="newbr"%s(zNewBrFlag) />
2039 @ Make this check-in the start of a new branch named:
2040 @ <input type="text" style="width:15;" name="brname" value="%h(zNewBranch)"
2041 @ onkeyup="gebi('newbr').checked=!!this.value" />
2042 @ </td></tr>
2043
2044 if( is_a_leaf(rid)
@@ -2046,13 +2060,13 @@
2046 " WHERE tagid=%d AND rid=%d AND tagtype>0",
2047 TAG_CLOSED, rid)
2048 ){
2049 @ <tr><td align="right" valign="top"><b>Leaf Closure:</b></td>
2050 @ <td valign="top">
2051 @ <input type="checkbox" name="close"%s(zCloseFlag) />
2052 @ Mark this leaf as "closed" so that it no longer appears on the
2053 @ "leaves" page and is no longer labeled as a "<b>Leaf</b>".
2054 @ </td></tr>
2055 }
2056
2057
2058 @ <tr><td colspan="2">
2059
--- src/info.c
+++ src/info.c
@@ -1691,17 +1691,17 @@
1691 int stdClrFound = 0;
1692 int i;
1693
1694 @ <table border="0" cellpadding="0" cellspacing="1">
1695 if( zIdPropagate ){
1696 @ <tr><td colspan="6" align="left"><label>
1697 if( fPropagate ){
1698 @ <input type="checkbox" name="%s(zIdPropagate)" checked="checked" />
1699 }else{
1700 @ <input type="checkbox" name="%s(zIdPropagate)" />
1701 }
1702 @ Propagate color to descendants</label></td></tr>
1703 }
1704 @ <tr>
1705 for(i=0; i<nColor; i++){
1706 const char *zClr = aColor[i].zColor;
1707 if( zClr==0 ) zClr = aColor[i].zCName;
@@ -1797,10 +1797,11 @@
1797 const char *zNewBrFlag;
1798 const char *zNewBranch;
1799 const char *zCloseFlag;
1800 int fPropagateColor; /* True if color propagates before edit */
1801 int fNewPropagateColor; /* True if color propagates after edit */
1802 const char *zChngTime = 0; /* Value of chngtime= query param, if any */
1803 char *zUuid;
1804 Blob comment;
1805 Stmt q;
1806
1807 login_check_credentials();
@@ -1811,10 +1812,11 @@
1812 " FROM event WHERE objid=%d", rid);
1813 if( zComment==0 ) fossil_redirect_home();
1814 if( P("cancel") ){
1815 cgi_redirectf("ci?name=%s", zUuid);
1816 }
1817 if( g.perm.Setup ) zChngTime = P("chngtime");
1818 zNewComment = PD("c",zComment);
1819 zUser = db_text(0, "SELECT coalesce(euser,user)"
1820 " FROM event WHERE objid=%d", rid);
1821 if( zUser==0 ) fossil_redirect_home();
1822 zNewUser = PDT("u",zUser);
@@ -1842,11 +1844,11 @@
1844 char *zNow;
1845 int nChng = 0;
1846
1847 login_verify_csrf_secret();
1848 blob_zero(&ctrl);
1849 zNow = date_in_standard_format(zChngTime ? zChngTime : "now");
1850 blob_appendf(&ctrl, "D %s\n", zNow);
1851 db_multi_exec("CREATE TEMP TABLE newtags(tag UNIQUE, prefix, value)");
1852 if( zNewColor[0]
1853 && (fPropagateColor!=fNewPropagateColor
1854 || fossil_strcmp(zColor,zNewColor)!=0)
@@ -1968,10 +1970,14 @@
1970 }
1971 db_finalize(&q);
1972 blob_appendf(&suffix, ")");
1973 @ %s(blob_str(&suffix))
1974 @ </td></tr></table>
1975 if( zChngTime ){
1976 @ <p>The timestamp on the tag used to make the changes above
1977 @ will be overridden as: %s(date_in_standard_format(zChngTime))</p>
1978 }
1979 @ </blockquote>
1980 @ <hr />
1981 blob_reset(&suffix);
1982 }
1983 @ <p>Make changes to attributes of check-in
@@ -1993,20 +1999,27 @@
1999
2000 @ <tr><td align="right" valign="top"><b>Check-in Time:</b></td>
2001 @ <td valign="top">
2002 @ <input type="text" name="dt" size="20" value="%h(zNewDate)" />
2003 @ </td></tr>
2004
2005 if( zChngTime ){
2006 @ <tr><td align="right" valign="top"><b>Timestamp of this change:</b></td>
2007 @ <td valign="top">
2008 @ <input type="text" name="chngtime" size="20" value="%h(zChngTime)" />
2009 @ </td></tr>
2010 }
2011
2012 @ <tr><td align="right" valign="top"><b>Background Color:</b></td>
2013 @ <td valign="top">
2014 render_color_chooser(fNewPropagateColor, zNewColor, "pclr", "clr", "clrcust");
2015 @ </td></tr>
2016
2017 @ <tr><td align="right" valign="top"><b>Tags:</b></td>
2018 @ <td valign="top">
2019 @ <label><input type="checkbox" id="newtag" name="newtag"%s(zNewTagFlag) />
2020 @ Add the following new tag name to this check-in:</label>
2021 @ <input type="text" style="width:15;" name="tagname" value="%h(zNewTag)"
2022 @ onkeyup="gebi('newtag').checked=!!this.value" />
2023 db_prepare(&q,
2024 "SELECT tag.tagid, tagname FROM tagxref, tag"
2025 " WHERE tagxref.rid=%d AND tagtype>0 AND tagxref.tagid=tag.tagid"
@@ -2017,28 +2030,29 @@
2030 while( db_step(&q)==SQLITE_ROW ){
2031 int tagid = db_column_int(&q, 0);
2032 const char *zTagName = db_column_text(&q, 1);
2033 char zLabel[30];
2034 sqlite3_snprintf(sizeof(zLabel), zLabel, "c%d", tagid);
2035 @ <br /><label>
2036 if( P(zLabel) ){
2037 @ <input type="checkbox" name="c%d(tagid)" checked="checked" />
2038 }else{
2039 @ <input type="checkbox" name="c%d(tagid)" />
2040 }
2041 if( strncmp(zTagName, "sym-", 4)==0 ){
2042 @ Cancel tag <b>%h(&zTagName[4])</b></label>
2043 }else{
2044 @ Cancel special tag <b>%h(zTagName)</b></label>
2045 }
2046 }
2047 db_finalize(&q);
2048 @ </td></tr>
2049
2050 @ <tr><td align="right" valign="top"><b>Branching:</b></td>
2051 @ <td valign="top">
2052 @ <label><input id="newbr" type="checkbox" name="newbr"%s(zNewBrFlag) />
2053 @ Make this check-in the start of a new branch named:</label>
2054 @ <input type="text" style="width:15;" name="brname" value="%h(zNewBranch)"
2055 @ onkeyup="gebi('newbr').checked=!!this.value" />
2056 @ </td></tr>
2057
2058 if( is_a_leaf(rid)
@@ -2046,13 +2060,13 @@
2060 " WHERE tagid=%d AND rid=%d AND tagtype>0",
2061 TAG_CLOSED, rid)
2062 ){
2063 @ <tr><td align="right" valign="top"><b>Leaf Closure:</b></td>
2064 @ <td valign="top">
2065 @ <label><input type="checkbox" name="close"%s(zCloseFlag) />
2066 @ Mark this leaf as "closed" so that it no longer appears on the
2067 @ "leaves" page and is no longer labeled as a "<b>Leaf</b>".</label>
2068 @ </td></tr>
2069 }
2070
2071
2072 @ <tr><td colspan="2">
2073
+1 -1
--- src/md5.c
+++ src/md5.c
@@ -264,11 +264,11 @@
264264
((uint32 *)ctx->in)[ 15 ] = ctx->bits[1];
265265
266266
MD5Transform(ctx->buf, (uint32 *)ctx->in);
267267
byteReverse((unsigned char *)ctx->buf, 4);
268268
memcpy(digest, ctx->buf, 16);
269
- memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */
269
+ memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */
270270
}
271271
272272
/*
273273
** Convert a digest into base-16. digest should be declared as
274274
** "unsigned char digest[16]" in the calling function. The MD5
275275
--- src/md5.c
+++ src/md5.c
@@ -264,11 +264,11 @@
264 ((uint32 *)ctx->in)[ 15 ] = ctx->bits[1];
265
266 MD5Transform(ctx->buf, (uint32 *)ctx->in);
267 byteReverse((unsigned char *)ctx->buf, 4);
268 memcpy(digest, ctx->buf, 16);
269 memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */
270 }
271
272 /*
273 ** Convert a digest into base-16. digest should be declared as
274 ** "unsigned char digest[16]" in the calling function. The MD5
275
--- src/md5.c
+++ src/md5.c
@@ -264,11 +264,11 @@
264 ((uint32 *)ctx->in)[ 15 ] = ctx->bits[1];
265
266 MD5Transform(ctx->buf, (uint32 *)ctx->in);
267 byteReverse((unsigned char *)ctx->buf, 4);
268 memcpy(digest, ctx->buf, 16);
269 memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */
270 }
271
272 /*
273 ** Convert a digest into base-16. digest should be declared as
274 ** "unsigned char digest[16]" in the calling function. The MD5
275
+1 -1
--- src/path.c
+++ src/path.c
@@ -89,11 +89,11 @@
8989
p = path.pAll;
9090
path.pAll = p->pAll;
9191
fossil_free(p);
9292
}
9393
bag_clear(&path.seen);
94
- memset(&path, 0, sizeof(&path));
94
+ memset(&path, 0, sizeof(path));
9595
}
9696
9797
/*
9898
** Construct the path from path.pStart to path.pEnd in the u.pTo fields.
9999
*/
100100
--- src/path.c
+++ src/path.c
@@ -89,11 +89,11 @@
89 p = path.pAll;
90 path.pAll = p->pAll;
91 fossil_free(p);
92 }
93 bag_clear(&path.seen);
94 memset(&path, 0, sizeof(&path));
95 }
96
97 /*
98 ** Construct the path from path.pStart to path.pEnd in the u.pTo fields.
99 */
100
--- src/path.c
+++ src/path.c
@@ -89,11 +89,11 @@
89 p = path.pAll;
90 path.pAll = p->pAll;
91 fossil_free(p);
92 }
93 bag_clear(&path.seen);
94 memset(&path, 0, sizeof(path));
95 }
96
97 /*
98 ** Construct the path from path.pStart to path.pEnd in the u.pTo fields.
99 */
100
+51 -24
--- src/setup.c
+++ src/setup.c
@@ -551,35 +551,62 @@
551551
@ </tr>
552552
@ <tr>
553553
@ <td class="usetupEditLabel">Capabilities:</td>
554554
@ <td>
555555
#define B(x) inherit[x]
556
+ @ <table border=0><tr><td valign="top">
556557
if( g.perm.Setup ){
557
- @ <input type="checkbox" name="as"%s(oas) />%s(B('s'))Setup<br />
558
- }
559
- @ <input type="checkbox" name="aa"%s(oaa) />%s(B('a'))Admin<br />
560
- @ <input type="checkbox" name="ad"%s(oad) />%s(B('d'))Delete<br />
561
- @ <input type="checkbox" name="ae"%s(oae) />%s(B('e'))Email<br />
562
- @ <input type="checkbox" name="ap"%s(oap) />%s(B('p'))Password<br />
563
- @ <input type="checkbox" name="ai"%s(oai) />%s(B('i'))Check-In<br />
564
- @ <input type="checkbox" name="ao"%s(oao) />%s(B('o'))Check-Out<br />
565
- @ <input type="checkbox" name="ah"%s(oah) />%s(B('h'))Hyperlinks<br />
566
- @ <input type="checkbox" name="au"%s(oau) />%s(B('u'))Reader<br />
567
- @ <input type="checkbox" name="av"%s(oav) />%s(B('v'))Developer<br />
568
- @ <input type="checkbox" name="ag"%s(oag) />%s(B('g'))Clone<br />
569
- @ <input type="checkbox" name="aj"%s(oaj) />%s(B('j'))Read Wiki<br />
570
- @ <input type="checkbox" name="af"%s(oaf) />%s(B('f'))New Wiki<br />
571
- @ <input type="checkbox" name="am"%s(oam) />%s(B('m'))Append Wiki<br />
572
- @ <input type="checkbox" name="ak"%s(oak) />%s(B('k'))Write Wiki<br />
573
- @ <input type="checkbox" name="ab"%s(oab) />%s(B('b'))Attachments<br />
574
- @ <input type="checkbox" name="ar"%s(oar) />%s(B('r'))Read Ticket<br />
575
- @ <input type="checkbox" name="an"%s(oan) />%s(B('n'))New Ticket<br />
576
- @ <input type="checkbox" name="ac"%s(oac) />%s(B('c'))Append Ticket<br />
577
- @ <input type="checkbox" name="aw"%s(oaw) />%s(B('w'))Write Ticket<br />
578
- @ <input type="checkbox" name="at"%s(oat) />%s(B('t'))Ticket Report<br />
579
- @ <input type="checkbox" name="ax"%s(oax) />%s(B('x'))Private<br />
580
- @ <input type="checkbox" name="az"%s(oaz) />%s(B('z'))Download Zip
558
+ @ <label><input type="checkbox" name="as"%s(oas) />%s(B('s'))Setup
559
+ @ </label><br />
560
+ }
561
+ @ <label><input type="checkbox" name="aa"%s(oaa) />%s(B('a'))Admin
562
+ @ </label><br />
563
+ @ <label><input type="checkbox" name="ad"%s(oad) />%s(B('d'))Delete
564
+ @ </label><br />
565
+ @ <label><input type="checkbox" name="ae"%s(oae) />%s(B('e'))Email
566
+ @ </label><br />
567
+ @ <label><input type="checkbox" name="ap"%s(oap) />%s(B('p'))Password
568
+ @ </label><br />
569
+ @ <label><input type="checkbox" name="ai"%s(oai) />%s(B('i'))Check-In
570
+ @ </label><br />
571
+ @ <label><input type="checkbox" name="ao"%s(oao) />%s(B('o'))Check-Out
572
+ @ </label><br />
573
+ @ <label><input type="checkbox" name="ah"%s(oah) />%s(B('h'))Hyperlinks
574
+ @ </label><br />
575
+ @ </td><td><td width="40"></td><td valign="top">
576
+ @ <label><input type="checkbox" name="au"%s(oau) />%s(B('u'))Reader
577
+ @ </label><br />
578
+ @ <label><input type="checkbox" name="av"%s(oav) />%s(B('v'))Developer
579
+ @ </label><br />
580
+ @ <label><input type="checkbox" name="ag"%s(oag) />%s(B('g'))Clone
581
+ @ </label><br />
582
+ @ <label><input type="checkbox" name="aj"%s(oaj) />%s(B('j'))Read Wiki
583
+ @ </label><br />
584
+ @ <label><input type="checkbox" name="af"%s(oaf) />%s(B('f'))New Wiki
585
+ @ </label><br />
586
+ @ <label><input type="checkbox" name="am"%s(oam) />%s(B('m'))Append Wiki
587
+ @ </label><br />
588
+ @ <label><input type="checkbox" name="ak"%s(oak) />%s(B('k'))Write Wiki
589
+ @ </label><br />
590
+ @ <label><input type="checkbox" name="ab"%s(oab) />%s(B('b'))Attachments
591
+ @ </label><br />
592
+ @ </td><td><td width="40"></td><td valign="top">
593
+ @ <label><input type="checkbox" name="ar"%s(oar) />%s(B('r'))Read Ticket
594
+ @ </label><br />
595
+ @ <label><input type="checkbox" name="an"%s(oan) />%s(B('n'))New Ticket
596
+ @ </label><br />
597
+ @ <label><input type="checkbox" name="ac"%s(oac) />%s(B('c'))Append Ticket
598
+ @ </label><br />
599
+ @ <label><input type="checkbox" name="aw"%s(oaw) />%s(B('w'))Write Ticket
600
+ @ </label><br />
601
+ @ <label><input type="checkbox" name="at"%s(oat) />%s(B('t'))Ticket Report
602
+ @ </label><br />
603
+ @ <label><input type="checkbox" name="ax"%s(oax) />%s(B('x'))Private
604
+ @ </label><br />
605
+ @ <label><input type="checkbox" name="az"%s(oaz) />%s(B('z'))Download Zip
606
+ @ </label>
607
+ @ </td></tr></table>
581608
@ </td>
582609
@ </tr>
583610
@ <tr>
584611
@ <td align="right">Password:</td>
585612
if( zPw[0] ){
586613
--- src/setup.c
+++ src/setup.c
@@ -551,35 +551,62 @@
551 @ </tr>
552 @ <tr>
553 @ <td class="usetupEditLabel">Capabilities:</td>
554 @ <td>
555 #define B(x) inherit[x]
 
556 if( g.perm.Setup ){
557 @ <input type="checkbox" name="as"%s(oas) />%s(B('s'))Setup<br />
558 }
559 @ <input type="checkbox" name="aa"%s(oaa) />%s(B('a'))Admin<br />
560 @ <input type="checkbox" name="ad"%s(oad) />%s(B('d'))Delete<br />
561 @ <input type="checkbox" name="ae"%s(oae) />%s(B('e'))Email<br />
562 @ <input type="checkbox" name="ap"%s(oap) />%s(B('p'))Password<br />
563 @ <input type="checkbox" name="ai"%s(oai) />%s(B('i'))Check-In<br />
564 @ <input type="checkbox" name="ao"%s(oao) />%s(B('o'))Check-Out<br />
565 @ <input type="checkbox" name="ah"%s(oah) />%s(B('h'))Hyperlinks<br />
566 @ <input type="checkbox" name="au"%s(oau) />%s(B('u'))Reader<br />
567 @ <input type="checkbox" name="av"%s(oav) />%s(B('v'))Developer<br />
568 @ <input type="checkbox" name="ag"%s(oag) />%s(B('g'))Clone<br />
569 @ <input type="checkbox" name="aj"%s(oaj) />%s(B('j'))Read Wiki<br />
570 @ <input type="checkbox" name="af"%s(oaf) />%s(B('f'))New Wiki<br />
571 @ <input type="checkbox" name="am"%s(oam) />%s(B('m'))Append Wiki<br />
572 @ <input type="checkbox" name="ak"%s(oak) />%s(B('k'))Write Wiki<br />
573 @ <input type="checkbox" name="ab"%s(oab) />%s(B('b'))Attachments<br />
574 @ <input type="checkbox" name="ar"%s(oar) />%s(B('r'))Read Ticket<br />
575 @ <input type="checkbox" name="an"%s(oan) />%s(B('n'))New Ticket<br />
576 @ <input type="checkbox" name="ac"%s(oac) />%s(B('c'))Append Ticket<br />
577 @ <input type="checkbox" name="aw"%s(oaw) />%s(B('w'))Write Ticket<br />
578 @ <input type="checkbox" name="at"%s(oat) />%s(B('t'))Ticket Report<br />
579 @ <input type="checkbox" name="ax"%s(oax) />%s(B('x'))Private<br />
580 @ <input type="checkbox" name="az"%s(oaz) />%s(B('z'))Download Zip
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
581 @ </td>
582 @ </tr>
583 @ <tr>
584 @ <td align="right">Password:</td>
585 if( zPw[0] ){
586
--- src/setup.c
+++ src/setup.c
@@ -551,35 +551,62 @@
551 @ </tr>
552 @ <tr>
553 @ <td class="usetupEditLabel">Capabilities:</td>
554 @ <td>
555 #define B(x) inherit[x]
556 @ <table border=0><tr><td valign="top">
557 if( g.perm.Setup ){
558 @ <label><input type="checkbox" name="as"%s(oas) />%s(B('s'))Setup
559 @ </label><br />
560 }
561 @ <label><input type="checkbox" name="aa"%s(oaa) />%s(B('a'))Admin
562 @ </label><br />
563 @ <label><input type="checkbox" name="ad"%s(oad) />%s(B('d'))Delete
564 @ </label><br />
565 @ <label><input type="checkbox" name="ae"%s(oae) />%s(B('e'))Email
566 @ </label><br />
567 @ <label><input type="checkbox" name="ap"%s(oap) />%s(B('p'))Password
568 @ </label><br />
569 @ <label><input type="checkbox" name="ai"%s(oai) />%s(B('i'))Check-In
570 @ </label><br />
571 @ <label><input type="checkbox" name="ao"%s(oao) />%s(B('o'))Check-Out
572 @ </label><br />
573 @ <label><input type="checkbox" name="ah"%s(oah) />%s(B('h'))Hyperlinks
574 @ </label><br />
575 @ </td><td><td width="40"></td><td valign="top">
576 @ <label><input type="checkbox" name="au"%s(oau) />%s(B('u'))Reader
577 @ </label><br />
578 @ <label><input type="checkbox" name="av"%s(oav) />%s(B('v'))Developer
579 @ </label><br />
580 @ <label><input type="checkbox" name="ag"%s(oag) />%s(B('g'))Clone
581 @ </label><br />
582 @ <label><input type="checkbox" name="aj"%s(oaj) />%s(B('j'))Read Wiki
583 @ </label><br />
584 @ <label><input type="checkbox" name="af"%s(oaf) />%s(B('f'))New Wiki
585 @ </label><br />
586 @ <label><input type="checkbox" name="am"%s(oam) />%s(B('m'))Append Wiki
587 @ </label><br />
588 @ <label><input type="checkbox" name="ak"%s(oak) />%s(B('k'))Write Wiki
589 @ </label><br />
590 @ <label><input type="checkbox" name="ab"%s(oab) />%s(B('b'))Attachments
591 @ </label><br />
592 @ </td><td><td width="40"></td><td valign="top">
593 @ <label><input type="checkbox" name="ar"%s(oar) />%s(B('r'))Read Ticket
594 @ </label><br />
595 @ <label><input type="checkbox" name="an"%s(oan) />%s(B('n'))New Ticket
596 @ </label><br />
597 @ <label><input type="checkbox" name="ac"%s(oac) />%s(B('c'))Append Ticket
598 @ </label><br />
599 @ <label><input type="checkbox" name="aw"%s(oaw) />%s(B('w'))Write Ticket
600 @ </label><br />
601 @ <label><input type="checkbox" name="at"%s(oat) />%s(B('t'))Ticket Report
602 @ </label><br />
603 @ <label><input type="checkbox" name="ax"%s(oax) />%s(B('x'))Private
604 @ </label><br />
605 @ <label><input type="checkbox" name="az"%s(oaz) />%s(B('z'))Download Zip
606 @ </label>
607 @ </td></tr></table>
608 @ </td>
609 @ </tr>
610 @ <tr>
611 @ <td align="right">Password:</td>
612 if( zPw[0] ){
613
+8 -8
--- src/user.c
+++ src/user.c
@@ -465,26 +465,26 @@
465465
}
466466
@ </table></center>
467467
db_finalize(&q);
468468
@ <hr>
469469
@ <form method="post" action="%s(g.zTop)/access_log">
470
- @ <input type="checkbox" name="delold">
471
- @ Delete all but the most recent 200 entries</input>
470
+ @ <label><input type="checkbox" name="delold">
471
+ @ Delete all but the most recent 200 entries</input></label>
472472
@ <input type="submit" name="deloldbtn" value="Delete"></input>
473473
@ </form>
474474
@ <form method="post" action="%s(g.zTop)/access_log">
475
- @ <input type="checkbox" name="delanon">
476
- @ Delete all entries for user "anonymous"</input>
475
+ @ <label><input type="checkbox" name="delanon">
476
+ @ Delete all entries for user "anonymous"</input></label>
477477
@ <input type="submit" name="delanonbtn" value="Delete"></input>
478478
@ </form>
479479
@ <form method="post" action="%s(g.zTop)/access_log">
480
- @ <input type="checkbox" name="delfail">
481
- @ Delete all failed login attempts</input>
480
+ @ <label><input type="checkbox" name="delfail">
481
+ @ Delete all failed login attempts</input></label>
482482
@ <input type="submit" name="delfailbtn" value="Delete"></input>
483483
@ </form>
484484
@ <form method="post" action="%s(g.zTop)/access_log">
485
- @ <input type="checkbox" name="delall">
486
- @ Delete all entries</input>
485
+ @ <label><input type="checkbox" name="delall">
486
+ @ Delete all entries</input></label>
487487
@ <input type="submit" name="delallbtn" value="Delete"></input>
488488
@ </form>
489489
style_footer();
490490
}
491491
--- src/user.c
+++ src/user.c
@@ -465,26 +465,26 @@
465 }
466 @ </table></center>
467 db_finalize(&q);
468 @ <hr>
469 @ <form method="post" action="%s(g.zTop)/access_log">
470 @ <input type="checkbox" name="delold">
471 @ Delete all but the most recent 200 entries</input>
472 @ <input type="submit" name="deloldbtn" value="Delete"></input>
473 @ </form>
474 @ <form method="post" action="%s(g.zTop)/access_log">
475 @ <input type="checkbox" name="delanon">
476 @ Delete all entries for user "anonymous"</input>
477 @ <input type="submit" name="delanonbtn" value="Delete"></input>
478 @ </form>
479 @ <form method="post" action="%s(g.zTop)/access_log">
480 @ <input type="checkbox" name="delfail">
481 @ Delete all failed login attempts</input>
482 @ <input type="submit" name="delfailbtn" value="Delete"></input>
483 @ </form>
484 @ <form method="post" action="%s(g.zTop)/access_log">
485 @ <input type="checkbox" name="delall">
486 @ Delete all entries</input>
487 @ <input type="submit" name="delallbtn" value="Delete"></input>
488 @ </form>
489 style_footer();
490 }
491
--- src/user.c
+++ src/user.c
@@ -465,26 +465,26 @@
465 }
466 @ </table></center>
467 db_finalize(&q);
468 @ <hr>
469 @ <form method="post" action="%s(g.zTop)/access_log">
470 @ <label><input type="checkbox" name="delold">
471 @ Delete all but the most recent 200 entries</input></label>
472 @ <input type="submit" name="deloldbtn" value="Delete"></input>
473 @ </form>
474 @ <form method="post" action="%s(g.zTop)/access_log">
475 @ <label><input type="checkbox" name="delanon">
476 @ Delete all entries for user "anonymous"</input></label>
477 @ <input type="submit" name="delanonbtn" value="Delete"></input>
478 @ </form>
479 @ <form method="post" action="%s(g.zTop)/access_log">
480 @ <label><input type="checkbox" name="delfail">
481 @ Delete all failed login attempts</input></label>
482 @ <input type="submit" name="delfailbtn" value="Delete"></input>
483 @ </form>
484 @ <form method="post" action="%s(g.zTop)/access_log">
485 @ <label><input type="checkbox" name="delall">
486 @ Delete all entries</input></label>
487 @ <input type="submit" name="delallbtn" value="Delete"></input>
488 @ </form>
489 style_footer();
490 }
491

Keyboard Shortcuts

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