Description: Insert trace headers at index 0
Author: David Bürgin <dbuergin@gluet.ch>
Bug: https://github.com/trusteddomainproject/OpenARC/pull/141

--- a/openarc/openarc.c
+++ b/openarc/openarc.c
@@ -3804,7 +3804,7 @@
 			strlcat(hfvalue, arc_hdr_value(sealhdr),
 			        sizeof hfvalue);
 
-			status = arcf_insheader(ctx, 1, hfname, hfvalue);
+			status = arcf_insheader(ctx, 0, hfname, hfvalue);
 			if (status == MI_FAILURE)
 			{
 				if (conf->conf_dolog)
@@ -3860,7 +3860,7 @@
 			                    " arc.chain=%s", arcchainbuf);
 		}
 
-		if (arcf_insheader(ctx, 1, AUTHRESULTSHDR,
+		if (arcf_insheader(ctx, 0, AUTHRESULTSHDR,
 		                   arcf_dstring_get(afc->mctx_tmpstr)) != MI_SUCCESS)
 		{
 			if (conf->conf_dolog)
@@ -3889,7 +3889,7 @@
 		         afc->mctx_jobid != NULL ? afc->mctx_jobid
 		                                 : (u_char *) JOBIDUNKNOWN);
 
-		if (arcf_insheader(ctx, 1, SWHEADERNAME, xfhdr) != MI_SUCCESS)
+		if (arcf_insheader(ctx, 0, SWHEADERNAME, xfhdr) != MI_SUCCESS)
 		{
 			if (conf->conf_dolog)
 			{
