Fixed sort of zero-length array in wsjt1.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/trunk@39 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Joe Taylor 2005-12-30 01:40:23 +00:00
parent 5b38cdeccd
commit c23a58f2c8
3 changed files with 20 additions and 19 deletions

View File

@ -26,8 +26,7 @@ c = -2 means sort x in decreasing order and carry y along.
nn = n
if (nn .lt. 1) then
print *,
+ 'the number of values to be sorted is not positive.'
print *,'n = ',nn,' kflag = ',kflag,' in ssort.'
return
endif
c

View File

@ -1,4 +1,4 @@
# ---------------------------------------------------------- WSJT
#---------------------------------------------------------- WSJT
from Tkinter import *
from tkFileDialog import *
import Pmw

34
wsjt1.f
View File

@ -264,24 +264,26 @@ C Now the multi-tone decoding
+ cfile6,ps0)
npkept=nline !Number of pings that were kept
call indexx(npkept,tping,indx) !Merge the ST and MT decodes
smax=0.
stbest=.false.
do i=1,npkept
j=indx(i)
if(pick .and. STFound .and.
+ line(j)(29:31).eq.' ') goto 10
write(lumsg,1050) line(j) !Write to decoded.txt
1050 format(a79)
if(lcum) write(21,1050) line(j) !Write to decoded.cum
read(line(j),1060) sig,msg3
1060 format(16x,f3.0,9x,a3)
if(sig.gt.smax) then
smax=sig
tbest=tping(j)
stbest = (msg3.ne.' ')
endif
10 enddo
if(npkept.gt.0) then
call indexx(npkept,tping,indx) !Merge the ST and MT decodes
do i=1,npkept
j=indx(i)
if(pick .and. STFound .and.
+ line(j)(29:31).eq.' ') goto 10
write(lumsg,1050) line(j) !Write to decoded.txt
1050 format(a79)
if(lcum) write(21,1050) line(j) !Write to decoded.cum
read(line(j),1060) sig,msg3
1060 format(16x,f3.0,9x,a3)
if(sig.gt.smax) then
smax=sig
tbest=tping(j)
stbest = (msg3.ne.' ')
endif
10 enddo
endif
dt=1.0/11025.0 !Compute spectrum for pink curve
if(stbest) then