From 8b958a8851c0f5a02a14671cdf1ca4389bbc95ff Mon Sep 17 00:00:00 2001 From: "John S. Urban" Date: Tue, 13 Jul 2021 14:39:08 -0400 Subject: initialize allocatable CHARACTER variables before they are used in a comparison --- src/fpm_sources.f90 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/fpm_sources.f90 b/src/fpm_sources.f90 index c781535..f129878 100644 --- a/src/fpm_sources.f90 +++ b/src/fpm_sources.f90 @@ -200,6 +200,9 @@ subroutine get_executable_source_dirs(exe_dirs,executables) integer :: i, n n = 0 + do i=1,size(executables) + dirs_temp(i)%s=' ' + enddo do i=1,size(executables) if (.not.(executables(i)%source_dir .in. dirs_temp)) then -- cgit v1.2.3 From 117690dda9d36cac4c22feb6f35618bd90d49cd3 Mon Sep 17 00:00:00 2001 From: Laurence Kedward Date: Sat, 26 Jun 2021 10:35:09 +0100 Subject: Merge pull request #504 from brocolis/version-number install.sh, README.md: Update version number, single source file extension --- src/fpm_sources.f90 | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/fpm_sources.f90 b/src/fpm_sources.f90 index f129878..c781535 100644 --- a/src/fpm_sources.f90 +++ b/src/fpm_sources.f90 @@ -200,9 +200,6 @@ subroutine get_executable_source_dirs(exe_dirs,executables) integer :: i, n n = 0 - do i=1,size(executables) - dirs_temp(i)%s=' ' - enddo do i=1,size(executables) if (.not.(executables(i)%source_dir .in. dirs_temp)) then -- cgit v1.2.3 From 76589b8e3cc9f93d3ec6ab96aa6688507376dd8f Mon Sep 17 00:00:00 2001 From: "John S. Urban" Date: Tue, 13 Jul 2021 16:04:01 -0400 Subject: settings%args was used unallocated --- src/fpm.f90 | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/fpm.f90 b/src/fpm.f90 index c670378..a80f1f6 100644 --- a/src/fpm.f90 +++ b/src/fpm.f90 @@ -423,11 +423,20 @@ subroutine cmd_run(settings,test) do i=1,size(executables) if (exists(executables(i)%s)) then if(settings%runner .ne. ' ')then - call run(settings%runner//' '//executables(i)%s//" "//settings%args, & + if(.not.allocated(settings%args))then + call run(settings%runner//' '//executables(i)%s, & echo=settings%verbose, exitstat=stat(i)) + else + call run(settings%runner//' '//executables(i)%s//" "//settings%args, & + echo=settings%verbose, exitstat=stat(i)) + endif else - call run(executables(i)%s//" "//settings%args,echo=settings%verbose, & + if(.not.allocated(settings%args))then + call run(executables(i)%s,echo=settings%verbose, exitstat=stat(i)) + else + call run(executables(i)%s//" "//settings%args,echo=settings%verbose, & exitstat=stat(i)) + endif endif else write(stderr,*)'fpm::run',executables(i)%s,' not found' -- cgit v1.2.3