JDimproved / JDim

2ch browser for linux
https://jdimproved.github.io/JDim/
GNU General Public License v2.0
46 stars 11 forks source link

BoardBase: Add const qualifier to pointer variables in local scope #1234

Closed ma8ma closed 1 year ago

ma8ma commented 1 year ago

ローカルのポインター変数にconstを付けられるとcppcheckに指摘されたため修正します。

cppcheck 2.11.1のレポート

src/dbtree/boardbase.cpp:705:18: style: Variable 'article' can be declared as pointer to const [constVariablePointer]
    ArticleBase* article = get_article_fromURL( url );
                 ^
src/dbtree/boardbase.cpp:2196:23: style: Variable 'art' can be declared as pointer to const [constVariablePointer]
    for( ArticleBase* art : m_list_subject ) {
                      ^
src/dbtree/boardbase.cpp:2347:23: style: Variable 'article' can be declared as pointer to const [constVariablePointer]
    for( ArticleBase* article : m_hash_article ) {
                      ^