[m-rev.] diff: fix string_format test problems under cygwin
Peter Ross
pro at missioncriticalit.com
Tue Dec 3 21:07:37 AEDT 2002
fjh wrote:
> On 02-Nov-2002, Peter Ross <pro at missioncriticalit.com> wrote:
> > Fix a problem with the tests on a text mount under cygwin. For some
> > unknown reason, the .sorted_out file produced contains ^M's when using
> > mmake. They don't occur when creating the output from the shell prompt.
>
> If you are on a text-mode mount, then the output *should* contain ^M's,
> shouldn't it?
>
Here is a cut down diff the string_format_c.log reports:
*** string_format_c.exp Tue Nov 19 10:42:27 2002
--- string_format_c.sorted_out Tue Dec 3 10:59:18 2002
***************
*** 1,80 ****
! %c:' '
--- 1,80 ----
! %c:' '^M
but if I run from the shell prompt
./string_format_c > ./string_format_c.out
cat string_format_c.out | sort > string_format_c.sorted
diff -u string_format_c.exp string_format_c.sorted
The diff succeeds.
So yes it should contain ^Ms but in both files not just the .exp.
> Which version of "sort.exe" do you have in your PATH -- the Windows
version
> or the Cygwin version? Maybe that is the problem.
>
No I am picking up the cygwin version of sort, as seen below.
{ [ -f string_format_c.inp ] && cat string_format_c.inp; } |
./string_format_c >
string_format_c.out 2>&1 || \
{ grep . string_format_c.out /dev/null | tail -n 20; exit 1; }
Comparing string_format_c.sorted_out with string_format_c.exp*,
results in string_format_c.res
which sort
/usr/bin/sort
** string_format_c.sorted_out did not match the expected output
** (closest match was string_format_c.res1)
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.419 / Virus Database: 235 - Release Date: 11/13/2002
--------------------------------------------------------------------------
mercury-reviews mailing list
post: mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the reviews
mailing list