Hi @smenna, I stumbled upon something with GCSORT. When providing empty input files in COPY mode, we receive the error GCSORT*S617*ERROR: Cannot open file. This does not happen in SORT/MERGE mode. Having empty input files seems legit to me - do we really want to error in this case ? Best regards
GCSORT FINDREP has no effect
Fix CHAR and ORD intrinsics in presence of collating sequence
Based on my observations, the buffer in output contains a size prefix (whose size is given by nSplitPos = SZPOSPNT = SIZEINT64), and globalJob->LenCurrRek is the size of the record without the size prefix. There are other places where nSplitPos is added to the record size, for instance in job.c at line 3945, we have: gc_memcpy((unsigned char*)szBuffRek, recordBuffer, job->phSrt->nLenRek + nSplitPosPnt); Also, experiments without adding nSplitPosPnt to globalJob->LenCurrRek results in missing data...
Based on my observations, the buffer in output contains a size prefix (whose size is given by nSplitPos = SZPOSPNT = SIZEINT64), and globalJob->LenCurrRek is the size of there record without the size prefix. There are other places where nSplitPos is added to the record size, for instance in job.c at line 3945, we have: gc_memcpy((unsigned char*)szBuffRek, recordBuffer, job->phSrt->nLenRek + nSplitPosPnt); Also, experiments without adding nSplitPosPnt to globalJob->LenCurrRek results in missing data...
GCSORT failure with FINDREP and STARTPOS <> 0
Merged revisions 5531, 5537, 5540-5542, 5549-5553 from branches/gnucobol-3.x:
Update GCSORT inline help for ORG LSF