Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Initialize variable.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Thu, 26 Nov 2020 21:32:21 +0000 (22:32 +0100)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Thu, 26 Nov 2020 22:43:57 +0000 (23:43 +0100)
Useless, but please PVS-studio.

teshsuite/smpi/type-struct/type-struct.c

index 4256885..2a4b38d 100644 (file)
 int main(int argc, char **argv)
 {
     int          rank;
-    struct { int a;int c; double b;int tab[2][3];} value;
+    struct {
+      int a;
+      int c;
+      double b;
+      int tab[2][3];
+    } value = {0};
     MPI_Datatype mystruct;
     int          blocklens[3];
     MPI_Aint     indices[3];