Output bugfix
This commit is contained in:
@@ -365,19 +365,22 @@ static long enumerate_tree(const enumeration_info_t *info, signed char *level, i
|
||||
level[head] = HEAD_MARKER;
|
||||
|
||||
int is_slim = transitive_closure(info, level, head, current_level);
|
||||
int is_fat;
|
||||
int is_balanced = 0;
|
||||
int count = 0;
|
||||
|
||||
// we have a candidate, check if it is a balanced thickening; if so, write to stdout
|
||||
if(is_slim) {
|
||||
is_fat = 1;
|
||||
is_balanced = 1;
|
||||
for(int i = head - 1; i >= 0; i--)
|
||||
if(level[i] == 0)
|
||||
is_fat = 0;
|
||||
is_balanced = 0;
|
||||
}
|
||||
|
||||
output_thickening(info, level, current_level, is_slim, is_fat, count);
|
||||
// comment this out (or just put it inside the if block) to save 1/3 of the runtime
|
||||
output_thickening(info, level, current_level, is_slim, is_balanced, count);
|
||||
|
||||
if(is_fat) {
|
||||
if(is_slim) {
|
||||
if(is_balanced) {
|
||||
count++;
|
||||
fwrite(level, sizeof(signed char), info->size, info->outfile);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user