[GRASS-QA] GRASS QA: markus | ./grass6/lib/sites/sites.c |1 clones
( sites.c )| 1 monsters | 1 warnings
grass-qa at proxy.soccerlab.polymtl.ca
grass-qa at proxy.soccerlab.polymtl.ca
Sun Aug 5 08:13:10 EDT 2007
Hello markus,
here a report on your recent GRASS-CVS change:
ANALYSIS
your changes to files/functions:
lib/sites/sites.c functions
site_att_cmp (Begins at: 38 Ends at: 49)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 0 | | OK |
LOC: | 12 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_get (Begins at: 51 Ends at: 100)
--------------+---------+-------+---------+
Complexity: | 10 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 10 | | OK |
LOC: | 50 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_put (Begins at: 104 Ends at: 141)
--------------+---------+-------+---------+
Complexity: | 5 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 9 | | OK |
LOC: | 38 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_describe (Begins at: 143 Ends at: 165)
--------------+---------+-------+---------+
Complexity: | 2 | | OK |
ParamNBR: | 5 | * | |
CalledNBR: | 3 | | OK |
LOC: | 23 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_put_head (Begins at: 171 Ends at: 213)
--------------+---------+-------+---------+
Complexity: | 8 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 9 | | OK |
LOC: | 43 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_get_head (Begins at: 219 Ends at: 289)
--------------+---------+-------+---------+
Complexity: | 4 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 8 | | OK |
LOC: | 71 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_find_sites (Begins at: 291 Ends at: 294)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_find_sites2 (Begins at: 297 Ends at: 300)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_ask_sites_new (Begins at: 303 Ends at: 306)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_ask_sites_old (Begins at: 309 Ends at: 312)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_ask_sites_any (Begins at: 315 Ends at: 318)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_ask_sites_in_mapset (Begins at: 321 Ends at: 324)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_sites_open_old (Begins at: 327 Ends at: 456)
--------------+---------+-------+---------+
Complexity: | 20 | * | |
ParamNBR: | 2 | | OK |
CalledNBR: | 42 | * | |
LOC: | 130 | * | |
--------------+---------+-------+---------+
metrics are OK
G_sites_open_new (Begins at: 459 Ends at: 473)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 5 | | OK |
LOC: | 15 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_sites_close (Begins at: 476 Ends at: 499)
--------------+---------+-------+---------+
Complexity: | 2 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 7 | | OK |
LOC: | 24 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_fopen_sites_old (Begins at: 507 Ends at: 510)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_fopen_sites_new (Begins at: 513 Ends at: 516)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_get_site (Begins at: 519 Ends at: 525)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 4 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 7 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_put_site (Begins at: 528 Ends at: 534)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 4 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 7 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_free_struct (Begins at: 539 Ends at: 551)
--------------+---------+-------+---------+
Complexity: | 4 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 4 | | OK |
LOC: | 13 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_new_struct (Begins at: 553 Ends at: 617)
--------------+---------+-------+---------+
Complexity: | 16 | * | |
ParamNBR: | 4 | | OK |
CalledNBR: | 17 | | OK |
LOC: | 65 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_oldsite_get (Begins at: 624 Ends at: 628)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 2 | | OK |
LOC: | 5 | | OK |
--------------+---------+-------+---------+
metrics are OK
G__oldsite_get (Begins at: 631 Ends at: 776)
--------------+---------+-------+---------+
Complexity: | 39 | *** | MONSTER |
ParamNBR: | 3 | | OK |
CalledNBR: | 29 | | OK |
LOC: | 146 | * | |
--------------+---------+-------+---------+
1 metric are OUT OF RANGE!
G_oldsite_describe (Begins at: 778 Ends at: 940)
--------------+---------+-------+---------+
Complexity: | 31 | ** | Warning |
ParamNBR: | 5 | * | |
CalledNBR: | 32 | | OK |
LOC: | 163 | * | |
--------------+---------+-------+---------+
at least 1 values are close to an outlier please consider revising code
G_site_in_region (Begins at: 942 Ends at: 956)
--------------+---------+-------+---------+
Complexity: | 2 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 15 | | OK |
--------------+---------+-------+---------+
metrics are OK
format_double (Begins at: 958 Ends at: 963)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 2 | | OK |
LOC: | 6 | | OK |
--------------+---------+-------+---------+
metrics are OK
cleanse_string (Begins at: 965 Ends at: 1018)
--------------+---------+-------+---------+
Complexity: | 9 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 5 | | OK |
LOC: | 54 | | OK |
--------------+---------+-------+---------+
metrics are OK
next_att (Begins at: 1020 Ends at: 1031)
--------------+---------+-------+---------+
Complexity: | 4 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 2 | | OK |
LOC: | 12 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_c_cmp (Begins at: 1033 Ends at: 1057)
--------------+---------+-------+---------+
Complexity: | 7 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 0 | | OK |
LOC: | 25 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_d_cmp (Begins at: 1059 Ends at: 1072)
--------------+---------+-------+---------+
Complexity: | 3 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 0 | | OK |
LOC: | 14 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_oldsite_s_cmp (Begins at: 1074 Ends at: 1092)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 19 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_oldsites_open_old (Begins at: 1094 Ends at: 1097)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_oldsites_open_new (Begins at: 1099 Ends at: 1102)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 1 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 4 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_site_format (Begins at: 1110 Ends at: 1217)
--------------+---------+-------+---------+
Complexity: | 7 | | OK |
ParamNBR: | 3 | | OK |
CalledNBR: | 22 | | OK |
LOC: | 108 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_sites_get_atts (Begins at: 1219 Ends at: 1226)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 2 | | OK |
CalledNBR: | 1 | | OK |
LOC: | 8 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_sites_get_fields (Begins at: 1233 Ends at: 1323)
--------------+---------+-------+---------+
Complexity: | 11 | | OK |
ParamNBR: | 4 | | OK |
CalledNBR: | 26 | | OK |
LOC: | 91 | | OK |
--------------+---------+-------+---------+
metrics are OK
G_sites_free_fields (Begins at: 1328 Ends at: 1334)
--------------+---------+-------+---------+
Complexity: | 1 | | OK |
ParamNBR: | 4 | | OK |
CalledNBR: | 4 | | OK |
LOC: | 7 | | OK |
--------------+---------+-------+---------+
metrics are OK
Clone analysis:
This file has 1 potentially cloned functions:
G_site_free_struct
In lib/sites/sites.c clones of G_site_free_struct are:
raster/r.univar2/stats.c free_univar_stat_struct
__________________________________________
Threshold GRASS6 key metrics values at 2007-08-05 are:
---------------------------+-----------+---------+
median | upper | outlier |
| quartile | limit |
---------------------------+-----------+---------+
Complexity (Cyclo): 5 | 25 | 37 |
ParamNBR: 2 | 6 | 9 |
CalledNBR: 10 | 60 | 88 |
LOC: 43 | 195 | 272 |
---------------------------+-----------+---------+
Measures (see below Web page for details):
Complexity (Cyclo): a complexity index
ParamNBR: number of passed parameters
CalledNBR: number of called functions
LOC: Lines Of Code
Message interpretation:
OK : Nothing to say at all
* : above 75 % of value warning
** : this is getting close to be out of range, consider revising the code
***: this is a monster, definitely you should revise this function
__________________________________________
Brought to you by:
SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory
http://web.soccerlab.polymtl.ca/grass-evolution/grass-browsers/grass-index-en.html
More information about the grass-qa
mailing list