diff options
author | FormerLurker <hochgebe@gmail.com> | 2021-07-17 18:13:08 +0300 |
---|---|---|
committer | FormerLurker <hochgebe@gmail.com> | 2021-07-17 18:13:08 +0300 |
commit | 4b2a112c139ce7f9909ba95f27cada3ecea2405b (patch) | |
tree | bfb1e2d132ec8b65dcfc09a1692baa5fe1847e70 | |
parent | 56ea16df55e0e37581688effac94e78ffc10f941 (diff) |
Fix travel statistics print in console app. Remove gcode length calculation check for non-debug builds.
-rw-r--r-- | ArcWelder/segmented_arc.cpp | 6 | ||||
-rw-r--r-- | ArcWelderConsole/ArcWelderConsole.cpp | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/ArcWelder/segmented_arc.cpp b/ArcWelder/segmented_arc.cpp index 568d964..60d50cd 100644 --- a/ArcWelder/segmented_arc.cpp +++ b/ArcWelder/segmented_arc.cpp @@ -394,11 +394,15 @@ int segmented_arc::get_shape_gcode_length() int num_parameters = 4 + (has_e ? 1 : 0) + (has_z ? 1: 0) + (has_f ? 1: 0); // Return the length of the gcode. int gcode_length = 2 + num_spaces + num_decimal_points + num_digits + num_minus_signs + num_decimals + num_parameters; + + // Keep this around in case we have any future issues with the gcode length calculation + #ifdef Debug std::string gcode = get_shape_gcode(); if (gcode.length() != gcode_length) { - return 10000; + return 9999999; } + #endif return gcode_length; diff --git a/ArcWelderConsole/ArcWelderConsole.cpp b/ArcWelderConsole/ArcWelderConsole.cpp index 37574ea..e64d9d4 100644 --- a/ArcWelderConsole/ArcWelderConsole.cpp +++ b/ArcWelderConsole/ArcWelderConsole.cpp @@ -389,7 +389,7 @@ int main(int argc, char* argv[]) { log_messages.clear(); log_messages.str(""); - if (results.progress.travel_statistics.total_count_source == results.progress.travel_statistics.total_count_source) + if (results.progress.travel_statistics.total_count_source == results.progress.travel_statistics.total_count_target) { log_messages << "Target File Travel Statistics: No travel arcs converted." ; } |