File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -356,6 +356,9 @@ ompi_op_t *ompi_op_create_user(bool commute,
356356 new_op -> o_flags |= OMPI_OP_FLAGS_COMMUTE ;
357357 }
358358
359+ strncpy (new_op -> o_name , "USER OP" , sizeof (new_op -> o_name ) - 1 );
360+ new_op -> o_name [sizeof (new_op -> o_name ) - 1 ] = '\0' ;
361+
359362 /* Set the user-defined callback function. The "fort_fn" member
360363 is part of a union, so it doesn't matter if this is a C or
361364 Fortan callback; we'll call the right flavor (per o_flags) at
@@ -446,6 +449,7 @@ static void ompi_op_construct(ompi_op_t *new_op)
446449 /* Provide a default of a high value. Useful for non-predefined ops. */
447450 new_op -> op_type = OMPI_OP_NUM_OF_TYPES ;
448451 new_op -> o_flags = 0 ;
452+ new_op -> o_name [0 ] = '\0' ;
449453
450454 /* assign entry in fortran <-> c translation array */
451455
You can’t perform that action at this time.
0 commit comments