@@ -628,9 +628,16 @@ private static void executeArtifactLoading(boolean sideAware) {
628
628
final var vizThread = getVizThread (doViz , progresses , theFrame );
629
629
vizThread .start ();
630
630
}
631
- theFuture .join ();
632
- if (theFrame != null ) {
633
- doViz .set (false );
631
+ try {
632
+ theFuture .join ();
633
+ } catch (Error e ) {
634
+ throw e ;
635
+ } catch (Throwable t ) {
636
+ throw new Error (t );
637
+ } finally {
638
+ if (theFrame != null ) {
639
+ doViz .set (false );
640
+ }
634
641
}
635
642
}
636
643
@@ -658,6 +665,7 @@ private static Thread getVizThread(AtomicBoolean doViz, HashMap<DependencyLoadTa
658
665
}
659
666
theFrame .dispose ();
660
667
});
668
+ vizThread .setDaemon (true );
661
669
vizThread .setName ("FalsePatternLib Download Visualizer" );
662
670
return vizThread ;
663
671
}
@@ -689,26 +697,22 @@ private static class DependencyLoadTask {
689
697
public volatile long downloaded = 0 ;
690
698
691
699
private void load () {
692
- try {
693
- setupLibraryNames ();
694
- if (loadedLibraries .containsKey (artifact )) {
695
- alreadyLoaded ();
696
- return ;
697
- }
698
- setupPaths ();
699
- if (tryLoadingExistingFile ()) {
700
+ setupLibraryNames ();
701
+ if (loadedLibraries .containsKey (artifact )) {
702
+ alreadyLoaded ();
703
+ return ;
704
+ }
705
+ setupPaths ();
706
+ if (tryLoadingExistingFile ()) {
707
+ return ;
708
+ }
709
+ validateDownloadsAllowed ();
710
+ for (var repo : mavenRepositories ) {
711
+ if (tryDownloadFromMaven (repo )) {
700
712
return ;
701
713
}
702
- validateDownloadsAllowed ();
703
- for (var repo : mavenRepositories ) {
704
- if (tryDownloadFromMaven (repo )) {
705
- return ;
706
- }
707
- }
708
- crashCouldNotDownload ();
709
- } catch (Exception e ) {
710
- LOG .fatal (e );
711
714
}
715
+ crashCouldNotDownload ();
712
716
}
713
717
714
718
private void crashCouldNotDownload () {
0 commit comments