diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-11-30 09:23:42 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-11-30 12:18:04 +0100 |
commit | 14b366e57a904c2c0d04804f15d8daf755f14541 (patch) | |
tree | 5997a5f1f60a5e0d418708948b408221ef50586c /soltools | |
parent | cabf739612a0e979ebcf76f40a24e66a354b10a5 (diff) |
loplugin:singlevalfields
Change-Id: I70dc861573fd1b3d799c88aa2a6d9a3eda0e2a43
Reviewed-on: https://gerrit.libreoffice.org/64327
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'soltools')
-rw-r--r-- | soltools/mkdepend/def.h | 2 | ||||
-rw-r--r-- | soltools/mkdepend/include.c | 10 |
2 files changed, 4 insertions, 8 deletions
diff --git a/soltools/mkdepend/def.h b/soltools/mkdepend/def.h index a452fd71f0e1..bd06c5f01378 100644 --- a/soltools/mkdepend/def.h +++ b/soltools/mkdepend/def.h @@ -116,8 +116,6 @@ struct inclist { boolean i_notified; /* whether we have revealed includes */ boolean i_marked; /* whether it's in the makefile */ boolean i_searched; /* whether we have read this */ - boolean i_included_sym; /* whether #include SYMBOL was found */ - /* Can't use i_list if TRUE */ }; struct filepointer { diff --git a/soltools/mkdepend/include.c b/soltools/mkdepend/include.c index f47b9d8efeab..b7a5df1caae8 100644 --- a/soltools/mkdepend/include.c +++ b/soltools/mkdepend/include.c @@ -56,7 +56,7 @@ struct inclist *inc_path(char *file, char *include, boolean dot, struct Includes * has already been expanded. */ for (ip = inclist; ip->i_file; ip++) - if ((strcmp(ip->i_incstring, include) == 0) && !ip->i_included_sym) + if (strcmp(ip->i_incstring, include) == 0) { found = TRUE; break; @@ -284,7 +284,6 @@ struct inclist *newinclude(char const *newfile, char const *incstring) if (inclistp == inclist + MAXFILES - 1) fatalerr("out of space: increase MAXFILES\n"); ip->i_file = copy(newfile); - ip->i_included_sym = FALSE; if (incstring == NULL) ip->i_incstring = ip->i_file; else @@ -312,10 +311,9 @@ void included_by(struct inclist *ip, struct inclist *newfile) for (i=0; i<ip->i_listlen; i++) if (ip->i_list[ i ] == newfile) { i = (int)strlen(newfile->i_file); - if (!ip->i_included_sym && - !(i > 2 && - newfile->i_file[i-1] == 'c' && - newfile->i_file[i-2] == '.')) + if (!(i > 2 && + newfile->i_file[i-1] == 'c' && + newfile->i_file[i-2] == '.')) { /* only complain if ip has */ /* no #include SYMBOL lines */ |