Index: Jenkins/TestRegen
===================================================================
--- Jenkins/TestRegen	(revision d0cf740960e7b0d6a1aaa654da24f27983ace9ac)
+++ Jenkins/TestRegen	(revision c344406c13592541d0fb55ffccc6fc4715f3dfa5)
@@ -95,10 +95,13 @@
 	def target_dir = pwd tmp: true
 
-	def email_subject = "[cforall dashboard][TEST REGEN# ${env.BUILD_NUMBER}] - Result"
-	def email_body = """This is an automated email from the Jenkins build machine. It was
+	dir( target_dir ) {
+
+		def email_subject = "[cforall dashboard][TEST REGEN# ${env.BUILD_NUMBER}] - Result"
+		def email_body = """This is an automated email from the Jenkins build machine. It was
 generated http://plg2:8082/dashboard."""
 
-	//send email notification
-	emailext body: email_body, subject: email_subject, to: user_email, attachmentsPattern: "${target_dir}/result.patch"
+		//send email notification
+		emailext body: email_body, subject: email_subject, to: user_email, attachmentsPattern: "**/*.patch"
+	}
 }
 
