Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FormerLurker/ArcWelderLib.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFormerLurker <hochgebe@gmail.com>2020-11-11 03:12:12 +0300
committerFormerLurker <hochgebe@gmail.com>2020-11-11 03:12:12 +0300
commitb995df6e38d0185f32f06cac87e781249975b738 (patch)
tree96be6f1646911832b6139a2a24bb0d99f6358694
parent2ce62496fc67d131d65bcfddb550156f6cd4c438 (diff)
Fix overwrite source if source and target are the same file.
-rw-r--r--ArcWelder/segmented_shape.h13
-rw-r--r--ArcWelderConsole/ArcWelderConsole.cpp4
-rw-r--r--ArcWelderConsole/ArcWelderConsole.vcxproj1
3 files changed, 3 insertions, 15 deletions
diff --git a/ArcWelder/segmented_shape.h b/ArcWelder/segmented_shape.h
index 505b465..b5b3cfb 100644
--- a/ArcWelder/segmented_shape.h
+++ b/ArcWelder/segmented_shape.h
@@ -26,19 +26,6 @@
#include <string>
#include <limits>
#define PI_DOUBLE 3.14159265358979323846
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.0000000001 // fail
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.001 // pass
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.0001 // pass
-// Todo: Figure out EXACTLY what this should be!!! 0.00001 is conservative
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.00001 // PASS , but fails to draw spiral test
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.000005 // Pass, but fails the spiral test
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.0000025 // Passes both... This is tricky...
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.000001 // fails on barbarian test!!!
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.0000001 // fail
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.0000005 // fail
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.00000075 // fail
-//#define CIRCLE_GENERATION_A_ZERO_TOLERANCE 0.000000875 // fail
-
#include <list>
#include "utilities.h"
diff --git a/ArcWelderConsole/ArcWelderConsole.cpp b/ArcWelderConsole/ArcWelderConsole.cpp
index 0299028..babb8de 100644
--- a/ArcWelderConsole/ArcWelderConsole.cpp
+++ b/ArcWelderConsole/ArcWelderConsole.cpp
@@ -227,11 +227,11 @@ int main(int argc, char* argv[])
}
// create a uuid with a tmp extension for the temporary file
-
- log_messages << "Source and target path are the same. The source file will be overwritten. Temporary file path: " << target_file_path;
+ log_messages << "Source and target path are the same. The source file will be overwritten. Temporary file path: " << temp_file_path;
p_logger->log(0, INFO, log_messages.str());
log_messages.clear();
log_messages.str("");
+ target_file_path = temp_file_path;
}
log_messages << "Processing Gcode\n";
log_messages << "\tSource File Path : " << source_file_path << "\n";
diff --git a/ArcWelderConsole/ArcWelderConsole.vcxproj b/ArcWelderConsole/ArcWelderConsole.vcxproj
index 7ffa03a..1433a00 100644
--- a/ArcWelderConsole/ArcWelderConsole.vcxproj
+++ b/ArcWelderConsole/ArcWelderConsole.vcxproj
@@ -114,6 +114,7 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<IncludePath>$(SolutionDir)\GcodeProcessorLib\;$(SolutionDir)\ArcWelder\;$(VC_IncludePath);$(WindowsSDK_IncludePath);$(SolutionDir)\TCLAP\</IncludePath>
+ <TargetName>ArcWelder</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>