Fossil SCM

Remove a harmless unused local variable. [forum:/forumpost/1d5c8db08a327fb4|Forum post 1d5c8db08a327fb4].

drh 2024-12-19 18:20 trunk
Commit 08ea1bd4abe06d63bfea8d590448569a9658912490c593ed395dac791706a3a6
1 file changed -2
--- src/forum.c
+++ src/forum.c
@@ -1830,11 +1830,10 @@
18301830
if( db_int(0, "SELECT count(*) FROM user "
18311831
" WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'")==0 ){
18321832
@ <p>No non-supervisor moderators
18331833
}else{
18341834
Stmt q = empty_Stmt;
1835
- int nRows = 0;
18361835
db_prepare(&q, "SELECT uid, login, cap FROM user "
18371836
"WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'"
18381837
" ORDER BY login");
18391838
@ <table class='bordered'>
18401839
@ <thead><tr><th>User</th><th>Capabilities</th></tr></thead>
@@ -1841,11 +1840,10 @@
18411840
@ <tbody>
18421841
while( SQLITE_ROW==db_step(&q) ){
18431842
const int iUid = db_column_int(&q, 0);
18441843
const char *zUser = db_column_text(&q, 1);
18451844
const char *zCap = db_column_text(&q, 2);
1846
- ++nRows;
18471845
@ <tr>
18481846
@ <td><a href='%R/setup_uedit?id=%d(iUid)'>%h(zUser)</a></td>
18491847
@ <td>(%h(zCap))</td>
18501848
@ </tr>
18511849
}
18521850
--- src/forum.c
+++ src/forum.c
@@ -1830,11 +1830,10 @@
1830 if( db_int(0, "SELECT count(*) FROM user "
1831 " WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'")==0 ){
1832 @ <p>No non-supervisor moderators
1833 }else{
1834 Stmt q = empty_Stmt;
1835 int nRows = 0;
1836 db_prepare(&q, "SELECT uid, login, cap FROM user "
1837 "WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'"
1838 " ORDER BY login");
1839 @ <table class='bordered'>
1840 @ <thead><tr><th>User</th><th>Capabilities</th></tr></thead>
@@ -1841,11 +1840,10 @@
1841 @ <tbody>
1842 while( SQLITE_ROW==db_step(&q) ){
1843 const int iUid = db_column_int(&q, 0);
1844 const char *zUser = db_column_text(&q, 1);
1845 const char *zCap = db_column_text(&q, 2);
1846 ++nRows;
1847 @ <tr>
1848 @ <td><a href='%R/setup_uedit?id=%d(iUid)'>%h(zUser)</a></td>
1849 @ <td>(%h(zCap))</td>
1850 @ </tr>
1851 }
1852
--- src/forum.c
+++ src/forum.c
@@ -1830,11 +1830,10 @@
1830 if( db_int(0, "SELECT count(*) FROM user "
1831 " WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'")==0 ){
1832 @ <p>No non-supervisor moderators
1833 }else{
1834 Stmt q = empty_Stmt;
 
1835 db_prepare(&q, "SELECT uid, login, cap FROM user "
1836 "WHERE cap GLOB '*5*' AND cap NOT GLOB '*[as6]*'"
1837 " ORDER BY login");
1838 @ <table class='bordered'>
1839 @ <thead><tr><th>User</th><th>Capabilities</th></tr></thead>
@@ -1841,11 +1840,10 @@
1840 @ <tbody>
1841 while( SQLITE_ROW==db_step(&q) ){
1842 const int iUid = db_column_int(&q, 0);
1843 const char *zUser = db_column_text(&q, 1);
1844 const char *zCap = db_column_text(&q, 2);
 
1845 @ <tr>
1846 @ <td><a href='%R/setup_uedit?id=%d(iUid)'>%h(zUser)</a></td>
1847 @ <td>(%h(zCap))</td>
1848 @ </tr>
1849 }
1850

Keyboard Shortcuts

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