Skip to content

Commit 00a01c4

Browse files
committed
Merge branch 'master'
2 parents 2c103c2 + 43c8a1d commit 00a01c4

3 files changed

Lines changed: 15 additions & 4 deletions

File tree

source/c_src/applications/aedit/src/set_stations.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,13 @@
1818
#include <string.h>
1919
#include <ctype.h>
2020
#include "aedit.h"
21+
#include "sizelimits.h"
2122

2223
int set_stations(char *arg1, char *arg2, char *remarg)
2324
{
2425
extern struct inputs inp;
2526
int l, i, j;
26-
char c, buf[150], outbuf[10];
27+
char c, buf[150], outbuf[150];
2728

2829
sprintf(buf,"%s%s%s",arg1,arg2,remarg);
2930
l = strlen(buf);
@@ -33,7 +34,7 @@ int set_stations(char *arg1, char *arg2, char *remarg)
3334
c = buf[i];
3435
if(isalpha(c)) {
3536
if(strchr(outbuf,c) == NULL) { /* No duplicates */
36-
if(j > 13) { /* Check for overflow */
37+
if(j > MAXSTEXP) { /* Check for overflow */
3738
msg("Too many stations listed",2);
3839
return(-1);
3940
}

source/cpp_src/DiFXInterface/src/MHO_DiFXBaselineProcessor.cc

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,17 @@ void MHO_DiFXBaselineProcessor::Organize()
325325

326326
if(ant1 != ant2) // cross-correlation
327327
{
328-
fScaleFactor = SCALE * fNBitsToFactor[fRefStationBits] * fNBitsToFactor[fRemStationBits];
328+
fScaleFactor = SCALE;
329+
if(fNBitsToFactor.find(fRefStationBits) != fNBitsToFactor.end() ){fScaleFactor *= fNBitsToFactor[fRefStationBits];}
330+
else
331+
{
332+
msg_warn("difx_interface", "reference station quantization bits: "<<fRefStationBits<<", not in Van Vleck correction table" << eom);
333+
}
334+
if(fNBitsToFactor.find(fRemStationBits) != fNBitsToFactor.end()){fScaleFactor *= fNBitsToFactor[fRemStationBits];}
335+
else
336+
{
337+
msg_warn("difx_interface", "remote station quantization bits: "<<fRemStationBits<<", not in Van Vleck correction table" << eom);
338+
}
329339
}
330340
else // auto-correlation
331341
{

tag-rev.last

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
a1465b
1+
4d690f

0 commit comments

Comments
 (0)