Fossil SCM
Fix harmless compiler warnings.
Commit
ea2e51515320126f1cedd52f62eb54cb7276bcb29c7c940bb61d60fd16a733db
Parent
07356e44c1a8cf7…
2 files changed
+1
-1
+31
-29
+1
-1
| --- src/email.c | ||
| +++ src/email.c | ||
| @@ -2112,11 +2112,11 @@ | ||
| 2112 | 2112 | ** A web-form to send an email message to the repository administrator, |
| 2113 | 2113 | ** or (with appropriate permissions) to anybody. |
| 2114 | 2114 | */ |
| 2115 | 2115 | void contact_admin_page(void){ |
| 2116 | 2116 | const char *zAdminEmail = db_get("email-admin",0); |
| 2117 | - unsigned int uSeed; | |
| 2117 | + unsigned int uSeed = 0; | |
| 2118 | 2118 | const char *zDecoded; |
| 2119 | 2119 | char *zCaptcha = 0; |
| 2120 | 2120 | |
| 2121 | 2121 | login_check_credentials(); |
| 2122 | 2122 | if( zAdminEmail==0 || zAdminEmail[0]==0 ){ |
| 2123 | 2123 |
| --- src/email.c | |
| +++ src/email.c | |
| @@ -2112,11 +2112,11 @@ | |
| 2112 | ** A web-form to send an email message to the repository administrator, |
| 2113 | ** or (with appropriate permissions) to anybody. |
| 2114 | */ |
| 2115 | void contact_admin_page(void){ |
| 2116 | const char *zAdminEmail = db_get("email-admin",0); |
| 2117 | unsigned int uSeed; |
| 2118 | const char *zDecoded; |
| 2119 | char *zCaptcha = 0; |
| 2120 | |
| 2121 | login_check_credentials(); |
| 2122 | if( zAdminEmail==0 || zAdminEmail[0]==0 ){ |
| 2123 |
| --- src/email.c | |
| +++ src/email.c | |
| @@ -2112,11 +2112,11 @@ | |
| 2112 | ** A web-form to send an email message to the repository administrator, |
| 2113 | ** or (with appropriate permissions) to anybody. |
| 2114 | */ |
| 2115 | void contact_admin_page(void){ |
| 2116 | const char *zAdminEmail = db_get("email-admin",0); |
| 2117 | unsigned int uSeed = 0; |
| 2118 | const char *zDecoded; |
| 2119 | char *zCaptcha = 0; |
| 2120 | |
| 2121 | login_check_credentials(); |
| 2122 | if( zAdminEmail==0 || zAdminEmail[0]==0 ){ |
| 2123 |
+31
-29
| --- src/main.c | ||
| +++ src/main.c | ||
| @@ -1838,41 +1838,43 @@ | ||
| 1838 | 1838 | if( g.fCgiTrace ){ |
| 1839 | 1839 | fossil_trace("######## Calling %s #########\n", pCmd->zName); |
| 1840 | 1840 | cgi_print_all(1, 1); |
| 1841 | 1841 | } |
| 1842 | 1842 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1843 | - /* | |
| 1844 | - ** The TH1 return codes from the hook will be handled as follows: | |
| 1845 | - ** | |
| 1846 | - ** TH_OK: The xFunc() and the TH1 notification will both be executed. | |
| 1847 | - ** | |
| 1848 | - ** TH_ERROR: The xFunc() will be skipped, the TH1 notification will be | |
| 1849 | - ** skipped. If the xFunc() is being hooked, the error message | |
| 1850 | - ** will be emitted. | |
| 1851 | - ** | |
| 1852 | - ** TH_BREAK: The xFunc() and the TH1 notification will both be skipped. | |
| 1853 | - ** | |
| 1854 | - ** TH_RETURN: The xFunc() will be executed, the TH1 notification will be | |
| 1855 | - ** skipped. | |
| 1856 | - ** | |
| 1857 | - ** TH_CONTINUE: The xFunc() will be skipped, the TH1 notification will be | |
| 1858 | - ** executed. | |
| 1859 | - */ | |
| 1860 | - int rc; | |
| 1861 | - if( !g.fNoThHook ){ | |
| 1862 | - rc = Th_WebpageHook(pCmd->zName+1, pCmd->eCmdFlags); | |
| 1863 | - }else{ | |
| 1864 | - rc = TH_OK; | |
| 1865 | - } | |
| 1866 | - if( rc==TH_OK || rc==TH_RETURN || rc==TH_CONTINUE ){ | |
| 1867 | - if( rc==TH_OK || rc==TH_RETURN ){ | |
| 1843 | + { | |
| 1844 | + /* | |
| 1845 | + ** The TH1 return codes from the hook will be handled as follows: | |
| 1846 | + ** | |
| 1847 | + ** TH_OK: The xFunc() and the TH1 notification will both be executed. | |
| 1848 | + ** | |
| 1849 | + ** TH_ERROR: The xFunc() will be skipped, the TH1 notification will be | |
| 1850 | + ** skipped. If the xFunc() is being hooked, the error message | |
| 1851 | + ** will be emitted. | |
| 1852 | + ** | |
| 1853 | + ** TH_BREAK: The xFunc() and the TH1 notification will both be skipped. | |
| 1854 | + ** | |
| 1855 | + ** TH_RETURN: The xFunc() will be executed, the TH1 notification will be | |
| 1856 | + ** skipped. | |
| 1857 | + ** | |
| 1858 | + ** TH_CONTINUE: The xFunc() will be skipped, the TH1 notification will be | |
| 1859 | + ** executed. | |
| 1860 | + */ | |
| 1861 | + int rc; | |
| 1862 | + if( !g.fNoThHook ){ | |
| 1863 | + rc = Th_WebpageHook(pCmd->zName+1, pCmd->eCmdFlags); | |
| 1864 | + }else{ | |
| 1865 | + rc = TH_OK; | |
| 1866 | + } | |
| 1867 | + if( rc==TH_OK || rc==TH_RETURN || rc==TH_CONTINUE ){ | |
| 1868 | + if( rc==TH_OK || rc==TH_RETURN ){ | |
| 1868 | 1869 | #endif |
| 1869 | - pCmd->xFunc(); | |
| 1870 | + pCmd->xFunc(); | |
| 1870 | 1871 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1871 | - } | |
| 1872 | - if( !g.fNoThHook && (rc==TH_OK || rc==TH_CONTINUE) ){ | |
| 1873 | - Th_WebpageNotify(pCmd->zName+1, pCmd->eCmdFlags); | |
| 1872 | + } | |
| 1873 | + if( !g.fNoThHook && (rc==TH_OK || rc==TH_CONTINUE) ){ | |
| 1874 | + Th_WebpageNotify(pCmd->zName+1, pCmd->eCmdFlags); | |
| 1875 | + } | |
| 1874 | 1876 | } |
| 1875 | 1877 | } |
| 1876 | 1878 | #endif |
| 1877 | 1879 | } |
| 1878 | 1880 | |
| 1879 | 1881 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1838,41 +1838,43 @@ | |
| 1838 | if( g.fCgiTrace ){ |
| 1839 | fossil_trace("######## Calling %s #########\n", pCmd->zName); |
| 1840 | cgi_print_all(1, 1); |
| 1841 | } |
| 1842 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1843 | /* |
| 1844 | ** The TH1 return codes from the hook will be handled as follows: |
| 1845 | ** |
| 1846 | ** TH_OK: The xFunc() and the TH1 notification will both be executed. |
| 1847 | ** |
| 1848 | ** TH_ERROR: The xFunc() will be skipped, the TH1 notification will be |
| 1849 | ** skipped. If the xFunc() is being hooked, the error message |
| 1850 | ** will be emitted. |
| 1851 | ** |
| 1852 | ** TH_BREAK: The xFunc() and the TH1 notification will both be skipped. |
| 1853 | ** |
| 1854 | ** TH_RETURN: The xFunc() will be executed, the TH1 notification will be |
| 1855 | ** skipped. |
| 1856 | ** |
| 1857 | ** TH_CONTINUE: The xFunc() will be skipped, the TH1 notification will be |
| 1858 | ** executed. |
| 1859 | */ |
| 1860 | int rc; |
| 1861 | if( !g.fNoThHook ){ |
| 1862 | rc = Th_WebpageHook(pCmd->zName+1, pCmd->eCmdFlags); |
| 1863 | }else{ |
| 1864 | rc = TH_OK; |
| 1865 | } |
| 1866 | if( rc==TH_OK || rc==TH_RETURN || rc==TH_CONTINUE ){ |
| 1867 | if( rc==TH_OK || rc==TH_RETURN ){ |
| 1868 | #endif |
| 1869 | pCmd->xFunc(); |
| 1870 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1871 | } |
| 1872 | if( !g.fNoThHook && (rc==TH_OK || rc==TH_CONTINUE) ){ |
| 1873 | Th_WebpageNotify(pCmd->zName+1, pCmd->eCmdFlags); |
| 1874 | } |
| 1875 | } |
| 1876 | #endif |
| 1877 | } |
| 1878 | |
| 1879 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -1838,41 +1838,43 @@ | |
| 1838 | if( g.fCgiTrace ){ |
| 1839 | fossil_trace("######## Calling %s #########\n", pCmd->zName); |
| 1840 | cgi_print_all(1, 1); |
| 1841 | } |
| 1842 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1843 | { |
| 1844 | /* |
| 1845 | ** The TH1 return codes from the hook will be handled as follows: |
| 1846 | ** |
| 1847 | ** TH_OK: The xFunc() and the TH1 notification will both be executed. |
| 1848 | ** |
| 1849 | ** TH_ERROR: The xFunc() will be skipped, the TH1 notification will be |
| 1850 | ** skipped. If the xFunc() is being hooked, the error message |
| 1851 | ** will be emitted. |
| 1852 | ** |
| 1853 | ** TH_BREAK: The xFunc() and the TH1 notification will both be skipped. |
| 1854 | ** |
| 1855 | ** TH_RETURN: The xFunc() will be executed, the TH1 notification will be |
| 1856 | ** skipped. |
| 1857 | ** |
| 1858 | ** TH_CONTINUE: The xFunc() will be skipped, the TH1 notification will be |
| 1859 | ** executed. |
| 1860 | */ |
| 1861 | int rc; |
| 1862 | if( !g.fNoThHook ){ |
| 1863 | rc = Th_WebpageHook(pCmd->zName+1, pCmd->eCmdFlags); |
| 1864 | }else{ |
| 1865 | rc = TH_OK; |
| 1866 | } |
| 1867 | if( rc==TH_OK || rc==TH_RETURN || rc==TH_CONTINUE ){ |
| 1868 | if( rc==TH_OK || rc==TH_RETURN ){ |
| 1869 | #endif |
| 1870 | pCmd->xFunc(); |
| 1871 | #ifdef FOSSIL_ENABLE_TH1_HOOKS |
| 1872 | } |
| 1873 | if( !g.fNoThHook && (rc==TH_OK || rc==TH_CONTINUE) ){ |
| 1874 | Th_WebpageNotify(pCmd->zName+1, pCmd->eCmdFlags); |
| 1875 | } |
| 1876 | } |
| 1877 | } |
| 1878 | #endif |
| 1879 | } |
| 1880 | |
| 1881 |