File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -511,7 +511,7 @@ static void DestroyTests(IOR_test_t *tests_head)
511
511
*/
512
512
static void DistributeHints (MPI_Comm com )
513
513
{
514
- char hint [MAX_HINTS ][MAX_STR ], fullHint [MAX_STR ], hintVariable [MAX_STR ];
514
+ char hint [MAX_HINTS ][MAX_STR ], fullHint [MAX_STR ], hintVariable [MAX_STR ], hintValue [ MAX_STR ] ;
515
515
int hintCount = 0 , i ;
516
516
517
517
if (rank == 0 ) {
@@ -537,9 +537,10 @@ static void DistributeHints(MPI_Comm com)
537
537
"cannot broadcast hints" );
538
538
strcpy (fullHint , hint [i ]);
539
539
strcpy (hintVariable , strtok (fullHint , "=" ));
540
+ strcpy (hintValue , strtok (NULL , "=" ));
540
541
if (getenv (hintVariable ) == NULL ) {
541
542
/* doesn't exist in this task's environment; better set it */
542
- if (putenv ( hint [ i ] ) != 0 )
543
+ if (setenv ( hintVariable , hintValue , 1 ) != 0 )
543
544
WARN ("cannot set environment variable" );
544
545
}
545
546
}
You can’t perform that action at this time.
0 commit comments