public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in app-text/csvfix/files: csvfix-1.10a-escape-exec.patch csvfix-1.10a-tests.patch
@ 2011-08-07 18:53 Tim Harder (radhermit)
  0 siblings, 0 replies; only message in thread
From: Tim Harder (radhermit) @ 2011-08-07 18:53 UTC (permalink / raw
  To: gentoo-commits

radhermit    11/08/07 18:53:36

  Added:                csvfix-1.10a-escape-exec.patch
                        csvfix-1.10a-tests.patch
  Log:
  Version bump
  
  (Portage version: 2.2.0_alpha47/cvs/Linux x86_64)

Revision  Changes    Path
1.1                  app-text/csvfix/files/csvfix-1.10a-escape-exec.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/csvfix/files/csvfix-1.10a-escape-exec.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/csvfix/files/csvfix-1.10a-escape-exec.patch?rev=1.1&content-type=text/plain

Index: csvfix-1.10a-escape-exec.patch
===================================================================
--- csvfix-build/csvfix/src/csved_exec.cpp.orig
+++ csvfix-build/csvfix/src/csved_exec.cpp
@@ -144,7 +144,9 @@
 		if ( n < 0 || n > MAX_PARAM ) {
 			CSVTHROW( "Invalid parameter: %" << p );
 		}
-		return (unsigned int) n < row.size() ? row[n] : "";
+		return (unsigned int) n < row.size()
+			? ALib::Escape( row[n], "\\'\"", "\\" )
+			: "";
 	}
 	else {
 		ATHROW( "Invalid parameter" );



1.1                  app-text/csvfix/files/csvfix-1.10a-tests.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/csvfix/files/csvfix-1.10a-tests.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/csvfix/files/csvfix-1.10a-tests.patch?rev=1.1&content-type=text/plain

Index: csvfix-1.10a-tests.patch
===================================================================
--- csvfix-build.orig/csvfix/tests/run1
+++ csvfix-build/csvfix/tests/run1
@@ -1,4 +1,4 @@
-#!bash
+#!/bin/bash
 # run1
 # run single test
 # copyright (C) 2008 Neil Butterworth
@@ -49,7 +49,7 @@
 fi
 
 # exe to be tested - used in tests
-CSVED=../bin/csvfix.exe
+CSVED=../bin/csvfix
 export CSVED
 
 if [ ! -f "$CSVED" ]
@@ -64,7 +64,7 @@
 fi
 
 # where to find diff & where to put output
-DIFF=/bin/diff
+DIFF=/usr/bin/diff
 DIFFOUT=tmp/_diffout
 WINDIFF="C:/Program Files/Microsoft Visual Studio/Common/Tools/WINDIFF.EXE"
 TEST=`basename $TEST`
@@ -133,5 +133,7 @@
 	fi
 else
 	echo "Execution problem with $TEST - please correct"
+	color_red "FAILED $TEST"
+	exit 1
 fi
 
--- csvfix-build.orig/csvfix/tests/runtests
+++ csvfix-build/csvfix/tests/runtests
@@ -1,4 +1,4 @@
-#!bash
+#!/bin/bash
 # runall.bash
 # run all tests and report
 
@@ -22,3 +22,8 @@
 echo $FAILS failed, $PASSES passed
 echo ""
 
+if [[ $FAILS -gt 0 ]]; then
+	exit 1
+else
+	exit 0
+fi






^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-08-07 18:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-07 18:53 [gentoo-commits] gentoo-x86 commit in app-text/csvfix/files: csvfix-1.10a-escape-exec.patch csvfix-1.10a-tests.patch Tim Harder (radhermit)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox