Salome HOME
merge from master
[tools/sat_salome.git] / products / patches / paraview-0012-LATA_64BITS_IDS.patch
1 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/arch.h ParaView/Utilities/VisItBridge/databases/readers/Lata/arch.h
2 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/arch.h   2020-12-22 12:04:51.219334522 +0100
3 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/arch.h        2020-12-22 12:06:26.188148423 +0100
4 @@ -29,6 +29,10 @@
5  
6  #ifndef arch_include_
7  #define arch_include_
8 -typedef int entier;
9 +typedef long entier;
10 +typedef long integer;
11 +typedef int True_int;
12 +#define INT_is_64_
13 +
14  #endif
15  
16 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.C ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.C
17 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.C       2020-03-23 22:18:49.000000000 +0100
18 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.C    2020-12-22 12:06:26.189148420 +0100
19 @@ -31,8 +31,8 @@
20  #include <string.h>
21  //Implemente_instanciable_sans_constructeur_ni_destructeur(ArrOfBit,"ArrOfBit",Objet_U);
22  
23 -const unsigned int ArrOfBit::SIZE_OF_INT_BITS = 5;
24 -const unsigned int ArrOfBit::DRAPEAUX_INT = 31;
25 +const unsigned long ArrOfBit::SIZE_OF_INT_BITS = 5;
26 +const unsigned long ArrOfBit::DRAPEAUX_INT = 31;
27  
28  // Description: Constructeur d'un tableau de taille n, non initialise
29  ArrOfBit::ArrOfBit(entier n)
30 @@ -59,7 +59,7 @@
31  }
32  
33  // Description:
34 -// Taille en "int" du tableau requis pour stocker un tableau de bits
35 +// Taille en "long" du tableau requis pour stocker un tableau de bits
36  // de taille donnees.
37  entier ArrOfBit::calculer_int_size(entier taille) const
38  {
39 @@ -83,7 +83,7 @@
40      {
41        entier oldsize = calculer_int_size(taille);
42        entier newsize = calculer_int_size(n);
43 -      unsigned int * newdata = new unsigned int[newsize];
44 +      unsigned long * newdata = new unsigned long[newsize];
45        entier size_copy = (newsize > oldsize) ? oldsize : newsize;
46        if (size_copy)
47          {
48 @@ -114,11 +114,11 @@
49            data = 0;
50          }
51        if (newsize > 0)
52 -        data = new unsigned int[newsize];
53 +        data = new unsigned long[newsize];
54      }
55    taille = array.taille;
56    if (taille)
57 -    memcpy(data, array.data, newsize * sizeof(unsigned int));
58 +    memcpy(data, array.data, newsize * sizeof(unsigned long));
59    return *this;
60  }
61  
62 @@ -127,7 +127,7 @@
63  
64  ArrOfBit& ArrOfBit::operator=(entier val)
65  {
66 -  unsigned int valeur = val ? (~((unsigned int) 0)) : 0;
67 +  unsigned long valeur = val ? (~((unsigned long) 0)) : 0;
68    entier size = calculer_int_size(taille);
69    entier i;
70    for (i = 0; i < size; i++)
71 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.h ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.h
72 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.h       2020-03-23 22:18:49.000000000 +0100
73 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfBit.h    2020-12-22 12:06:26.189148420 +0100
74 @@ -55,18 +55,18 @@
75    entier calculer_int_size(entier taille) const;
76  protected:
77    entier taille;
78 -  unsigned int *data;
79 -  static const unsigned int SIZE_OF_INT_BITS;
80 -  static const unsigned int DRAPEAUX_INT;
81 +  unsigned long *data;
82 +  static const unsigned long SIZE_OF_INT_BITS;
83 +  static const unsigned long DRAPEAUX_INT;
84  };
85  
86  // Description: Renvoie 1 si le bit e est mis, 0 sinon.
87  inline entier ArrOfBit::operator[](entier e) const
88  {
89    assert(e >= 0 && e < taille);
90 -  unsigned int i = (unsigned int) e;
91 -  unsigned int x = data[i >> SIZE_OF_INT_BITS];
92 -  unsigned int flag = 1 << (i & DRAPEAUX_INT);
93 +  unsigned long i = (unsigned long) e;
94 +  unsigned long x = data[i >> SIZE_OF_INT_BITS];
95 +  unsigned long flag = 1 << (i & DRAPEAUX_INT);
96    entier resultat = ((x & flag) != 0) ? 1 : 0;
97    return resultat;
98  }
99 @@ -75,8 +75,8 @@
100  inline void ArrOfBit::setbit(entier e) const
101  {
102    assert(e >= 0 && e < taille);
103 -  unsigned int i = (unsigned int) e;
104 -  unsigned int flag = 1 << (i & DRAPEAUX_INT);
105 +  unsigned long i = (unsigned long) e;
106 +  unsigned long flag = 1 << (i & DRAPEAUX_INT);
107    data[i >> SIZE_OF_INT_BITS] |= flag;
108  }
109  
110 @@ -84,10 +84,10 @@
111  inline entier ArrOfBit::testsetbit(entier e) const
112  {
113    assert(e >= 0 && e < taille);
114 -  unsigned int i = (unsigned int) e;
115 -  unsigned int flag = 1 << (i & DRAPEAUX_INT);
116 +  unsigned long i = (unsigned long) e;
117 +  unsigned long flag = 1 << (i & DRAPEAUX_INT);
118    entier index = i >> SIZE_OF_INT_BITS;
119 -  unsigned int old = data[index];
120 +  unsigned long old = data[index];
121    data[index] = old | flag;
122    return ((old & flag) != 0) ? 1 : 0;
123  }
124 @@ -96,8 +96,8 @@
125  inline void ArrOfBit::clearbit(entier e) const
126  {
127    assert(e >= 0 && e < taille);
128 -  unsigned int i = (unsigned int) e;
129 -  unsigned int flag = 1 << (i & DRAPEAUX_INT);
130 +  unsigned long i = (unsigned long) e;
131 +  unsigned long flag = 1 << (i & DRAPEAUX_INT);
132    data[i >> SIZE_OF_INT_BITS] &= ~flag;
133  }
134  
135 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfDouble.C ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfDouble.C
136 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfDouble.C    2020-03-23 22:18:49.000000000 +0100
137 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfDouble.C 2020-12-22 12:06:26.189148420 +0100
138 @@ -210,7 +210,7 @@
139  // Description:
140  //     Un nouveau tableau utilise cette zone memoire :
141  //     incremente ref_count
142 -// Retour: int
143 +// Retour: long
144  //    Signification: ref_count
145  inline entier VDoubledata::add_one_ref()
146  {
147 @@ -222,7 +222,7 @@
148  //     decremente ref_count
149  // Precondition:
150  //     ref_count_ > 0
151 -// Retour: int
152 +// Retour: long
153  //    Signification: ref_count
154  inline entier VDoubledata::suppr_one_ref()
155  {
156 @@ -651,7 +651,7 @@
157  // Precondition:
158  // Parametre: const ArrOfDouble& dx
159  //    Signification: tableau a utiliser
160 -// Retour: int
161 +// Retour: long
162  //    Signification: indice du min
163  entier imin_array(const ArrOfDouble& dx)
164  {
165 @@ -679,7 +679,7 @@
166  // Precondition:
167  // Parametre: const ArrOfDouble& dx
168  //    Signification: tableau a utiliser
169 -// Retour: int
170 +// Retour: long
171  //    Signification: indice du max
172  entier imax_array(const ArrOfDouble& dx)
173  {
174 @@ -834,7 +834,7 @@
175  //   * annule p_, data_ et size_array_
176  //  Si le tableau est "ref_data" :
177  //   * annule data_ et size_array_
178 -// Retour: int
179 +// Retour: long
180  //    Signification: 1 si les donnees du tableau ont ete supprimees
181  // Precondition:
182  // Postcondition:
183 @@ -965,7 +965,7 @@
184  // Description:
185  //    Retourne le nombre de references des donnees du tableau
186  //    si le tableau est "normal", -1 s'il est "detache" ou "ref_data"
187 -// Retour: int
188 +// Retour: long
189  //    Signification: ref_count_
190  entier ArrOfDouble::ref_count() const
191  {
192 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfFloat.C ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfFloat.C
193 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfFloat.C     2020-03-23 22:18:49.000000000 +0100
194 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfFloat.C  2020-12-22 12:06:26.190148418 +0100
195 @@ -210,7 +210,7 @@
196  // Description:
197  //     Un nouveau tableau utilise cette zone memoire :
198  //     incremente ref_count
199 -// Retour: int
200 +// Retour: long
201  //    Signification: ref_count
202  inline entier VFloatdata::add_one_ref()
203  {
204 @@ -222,7 +222,7 @@
205  //     decremente ref_count
206  // Precondition:
207  //     ref_count_ > 0
208 -// Retour: int
209 +// Retour: long
210  //    Signification: ref_count
211  inline entier VFloatdata::suppr_one_ref()
212  {
213 @@ -651,7 +651,7 @@
214  // Precondition:
215  // Parametre: const ArrOfFloat& dx
216  //    Signification: tableau a utiliser
217 -// Retour: int
218 +// Retour: long
219  //    Signification: indice du min
220  entier imin_array(const ArrOfFloat& dx)
221  {
222 @@ -679,7 +679,7 @@
223  // Precondition:
224  // Parametre: const ArrOfFloat& dx
225  //    Signification: tableau a utiliser
226 -// Retour: int
227 +// Retour: long
228  //    Signification: indice du max
229  entier imax_array(const ArrOfFloat& dx)
230  {
231 @@ -834,7 +834,7 @@
232  //   * annule p_, data_ et size_array_
233  //  Si le tableau est "ref_data" :
234  //   * annule data_ et size_array_
235 -// Retour: int
236 +// Retour: long
237  //    Signification: 1 si les donnees du tableau ont ete supprimees
238  // Precondition:
239  // Postcondition:
240 @@ -965,7 +965,7 @@
241  // Description:
242  //    Retourne le nombre de references des donnees du tableau
243  //    si le tableau est "normal", -1 s'il est "detache" ou "ref_data"
244 -// Retour: int
245 +// Retour: long
246  //    Signification: ref_count_
247  entier ArrOfFloat::ref_count() const
248  {
249 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfInt.C ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfInt.C
250 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOfInt.C       2020-03-23 22:18:49.000000000 +0100
251 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOfInt.C    2020-12-22 12:06:26.190148418 +0100
252 @@ -211,7 +211,7 @@
253  // Description:
254  //     Un nouveau tableau utilise cette zone memoire :
255  //     incremente ref_count
256 -// Retour: int
257 +// Retour: long
258  //    Signification: ref_count
259  inline entier VIntdata::add_one_ref()
260  {
261 @@ -223,7 +223,7 @@
262  //     decremente ref_count
263  // Precondition:
264  //     ref_count_ > 0
265 -// Retour: int
266 +// Retour: long
267  //    Signification: ref_count
268  inline entier VIntdata::suppr_one_ref()
269  {
270 @@ -646,7 +646,7 @@
271  // Precondition:
272  // Parametre: const ArrOfInt& dx
273  //    Signification: tableau a utiliser
274 -// Retour: int
275 +// Retour: long
276  //    Signification: indice du min
277  entier imin_array(const ArrOfInt& dx)
278  {
279 @@ -674,7 +674,7 @@
280  // Precondition:
281  // Parametre: const ArrOfInt& dx
282  //    Signification: tableau a utiliser
283 -// Retour: int
284 +// Retour: long
285  //    Signification: indice du max
286  entier imax_array(const ArrOfInt& dx)
287  {
288 @@ -824,7 +824,7 @@
289  //   * annule p_, data_ et size_array_
290  //  Si le tableau est "ref_data" :
291  //   * annule data_ et size_array_
292 -// Retour: int
293 +// Retour: long
294  //    Signification: 1 si les donnees du tableau ont ete supprimees
295  // Precondition:
296  // Postcondition:
297 @@ -955,7 +955,7 @@
298  // Description:
299  //    Retourne le nombre de references des donnees du tableau
300  //    si le tableau est "normal", -1 s'il est "detache" ou "ref_data"
301 -// Retour: int
302 +// Retour: long
303  //    Signification: ref_count_
304  entier ArrOfInt::ref_count() const
305  {
306 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOf_Scalar_Prototype.cpp.h ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOf_Scalar_Prototype.cpp.h
307 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/ArrOf_Scalar_Prototype.cpp.h     2020-03-23 22:18:49.000000000 +0100
308 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/ArrOf_Scalar_Prototype.cpp.h  2020-12-22 12:06:26.191148416 +0100
309 @@ -182,7 +182,7 @@
310  // Description:
311  //     Un nouveau tableau utilise cette zone memoire :
312  //     incremente ref_count
313 -// Retour: int
314 +// Retour: long
315  //    Signification: ref_count
316  inline entier V__Scalar__data::add_one_ref()
317  {
318 @@ -194,7 +194,7 @@
319  //     decremente ref_count
320  // Precondition:
321  //     ref_count_ > 0
322 -// Retour: int
323 +// Retour: long
324  //    Signification: ref_count
325  inline entier V__Scalar__data::suppr_one_ref()
326  {
327 @@ -628,7 +628,7 @@
328  // Precondition:
329  // Parametre: const ArrOf__Scalar__& dx
330  //    Signification: tableau a utiliser
331 -// Retour: int
332 +// Retour: long
333  //    Signification: indice du min
334  entier imin_array(const ArrOf__Scalar__& dx)
335  {
336 @@ -656,7 +656,7 @@
337  // Precondition:
338  // Parametre: const ArrOf__Scalar__& dx
339  //    Signification: tableau a utiliser
340 -// Retour: int
341 +// Retour: long
342  //    Signification: indice du max
343  entier imax_array(const ArrOf__Scalar__& dx)
344  {
345 @@ -726,7 +726,7 @@
346  // Description:
347  //   Fonction de comparaison utilisee pour trier le tableau
348  //   dans ArrOf__Scalar__::trier(). Voir man qsort
349 -static int fonction_compare_arrof__scalar___ordonner(const void * data1, const void * data2)
350 +static long fonction_compare_arrof__scalar___ordonner(const void * data1, const void * data2)
351  {
352    const __scalar__ x = *(const __scalar__*)data1;
353    const __scalar__ y = *(const __scalar__*)data2;
354 @@ -816,7 +816,7 @@
355  //   * annule p_, data_ et size_array_
356  //  Si le tableau est "ref_data" :
357  //   * annule data_ et size_array_
358 -// Retour: int
359 +// Retour: long
360  //    Signification: 1 si les donnees du tableau ont ete supprimees
361  // Precondition:
362  // Postcondition:
363 @@ -947,7 +947,7 @@
364  // Description:
365  //    Retourne le nombre de references des donnees du tableau
366  //    si le tableau est "normal", -1 s'il est "detache" ou "ref_data"
367 -// Retour: int
368 +// Retour: long
369  //    Signification: ref_count_
370  entier ArrOf__Scalar__::ref_count() const
371  {
372 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/EFichier.h ParaView/Utilities/VisItBridge/databases/readers/Lata/EFichier.h
373 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/EFichier.h       2020-03-23 22:18:49.000000000 +0100
374 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/EFichier.h    2020-12-22 12:06:26.191148416 +0100
375 @@ -33,7 +33,7 @@
376  class EFichier : public Entree
377  {
378  public:
379 -  int ouvrir(const char *name)
380 +  long ouvrir(const char *name)
381    {
382      is_.open(name);
383      return is_.good();
384 @@ -42,11 +42,11 @@
385    {
386      return is_;
387    }
388 -  int eof()
389 +  long eof()
390    {
391      return is_.eof();
392    }
393 -  int good()
394 +  long good()
395    {
396      return is_.good();
397    }
398 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Entree.h ParaView/Utilities/VisItBridge/databases/readers/Lata/Entree.h
399 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Entree.h 2020-03-23 22:18:49.000000000 +0100
400 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/Entree.h      2020-12-22 12:06:26.191148416 +0100
401 @@ -37,8 +37,8 @@
402  {
403  public:
404    virtual operator std::istream& () = 0;
405 -  virtual int eof() = 0;
406 -  virtual int good() = 0;
407 +  virtual long eof() = 0;
408 +  virtual long good() = 0;
409    virtual ~Entree() {};
410    virtual std::istream& get_istream() = 0;
411  };
412 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDB.C ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDB.C
413 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDB.C 2020-03-23 22:18:49.000000000 +0100
414 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDB.C      2020-12-22 12:06:26.192148414 +0100
415 @@ -49,8 +49,8 @@
416  //  Dump detailed subbloc interpretation at level+1
417  #define verb_level_data_bloc 5
418  
419 -typedef int LataDBInt32;
420 -typedef long long int LataDBInt64;
421 +typedef long LataDBInt32;
422 +typedef long long LataDBInt64;
423  
424  void arch_check()
425  {
426 @@ -106,7 +106,7 @@
427    field_name_ = n;
428  }
429  
430 -int Field_UName::operator==(const Field_UName & f) const
431 +long Field_UName::operator==(const Field_UName & f) const
432  {
433    return (geometry_ == f.geometry_) && (field_name_ == f.field_name_) && (loc_ == f.loc_);
434  }
435 @@ -291,7 +291,7 @@
436        else 
437          {
438            if (msb_ != LataDBDataType::machine_msb_) {
439 -            Journal() << "LataDB LataDataFile::write(int) not coded for reverse binary msb" << endl;
440 +            Journal() << "LataDB LataDataFile::write(long) not coded for reverse binary msb" << endl;
441              throw;
442            }
443            switch(mode) {
444 @@ -306,7 +306,7 @@
445        }
446      }
447    }
448 -  void set_exception(int i) { exception_ = i; }
449 +  void set_exception(long i) { exception_ = i; }
450    FileOffset position() { return (*stream_).tellp(); };
451    enum SeekType { ABSOLUTE, RELATIVE };
452    void seek(FileOffset pos, SeekType seekt) {
453 @@ -369,7 +369,7 @@
454    std::iostream *stream_; // Points to fstream_ or mem_buffer passed to constructor
455    LataDBDataType::MSB msb_;
456    LataDBDataType::Type type_;
457 -  int exception_;
458 +  long exception_;
459  };
460  
461  void LataDataFile::read(LataDBInt32 *ptr, BigEntier n)
462 @@ -381,9 +381,9 @@
463    if (msb_ == LataDBDataType::ASCII) {
464      BigEntier i;
465      if (ptr)
466 -      Journal(verb_level_data_bloc+1) << "Reading ascii int data bloc size=" << n << endl;
467 +      Journal(verb_level_data_bloc+1) << "Reading ascii long data bloc size=" << n << endl;
468      else
469 -      Journal(verb_level_data_bloc+1) << "Skipping ascii int data bloc size=" << n << endl;
470 +      Journal(verb_level_data_bloc+1) << "Skipping ascii long data bloc size=" << n << endl;
471      LataDBInt32 toto;
472      for (i = 0; i < n; i++) {
473        if (ptr)
474 @@ -397,15 +397,15 @@
475        }
476      }
477    } else {
478 -    if (type_ != LataDBDataType::INT32) {
479 +    if ((type_ != LataDBDataType::INT64) &&  (type_ != LataDBDataType::INT32)) {
480        Journal() << "Internal error in LataDB.cpp LataDataFile::read(LataDBInt32) : size conversion not coded" << endl;
481        throw;
482      }
483      if (ptr) {
484 -      Journal(verb_level_data_bloc+1) << "Reading binary int data bloc size=" << n << endl;
485 +      Journal(verb_level_data_bloc+1) << "Reading binary long data bloc size=" << n << endl;
486        (*stream_).read((char*)ptr, n * sizeof(LataDBInt32));
487      } else {
488 -      Journal(verb_level_data_bloc+1) << "Skipping binary int data bloc size=" << n << endl;
489 +      Journal(verb_level_data_bloc+1) << "Skipping binary long data bloc size=" << n << endl;
490        seek(n * sizeof(LataDBInt32), RELATIVE);
491      }
492      if (exception_ && !(*stream_).good()) {
493 @@ -468,7 +468,7 @@
494  
495  void LataDataFile::write(const LataDBInt32 *ptr, BigEntier n, BigEntier columns)
496  {
497 -  Journal(verb_level_data_bloc+1) << "Writing int data bloc size=" << n << endl;
498 +  Journal(verb_level_data_bloc+1) << "Writing long data bloc size=" << n << endl;
499    if (type_ != LataDBDataType::INT32) {
500      Journal() << "Error in lataDB bloc write: trying to write integer data to non integer file block" << endl;
501      throw LataDBError(LataDBError::DATA_ERROR); 
502 @@ -482,7 +482,7 @@
503      }
504    } else {
505      if (msb_ != LataDBDataType::machine_msb_) {
506 -      Journal() << "LataDB LataDataFile::write(int) not coded for reverse binary msb" << endl;
507 +      Journal() << "LataDB LataDataFile::write(long) not coded for reverse binary msb" << endl;
508        throw;
509        // Put code here (and test !) to reverse bytes in the binary bloc:
510      }
511 @@ -490,7 +490,7 @@
512    }
513    (*stream_).seekg(0, std::ios::end);
514    if (exception_ && !(*stream_).good()) {
515 -    Journal() << "Error writing file " << fname_ << " int[" << n << "]" 
516 +    Journal() << "Error writing file " << fname_ << " long[" << n << "]" 
517                << endl << message_ << endl;
518      throw LataDBError(LataDBError::DATA_ERROR);
519    }
520 @@ -533,7 +533,7 @@
521      return;
522    f.set_err_message("Error reading fortran blocsize");
523    f.set_encoding(type.msb_, type.bloc_marker_type_);
524 -  int i;
525 +  long i;
526    f >> i;
527    Journal(verb_level_data_bloc+1) << "Skipping blocsize marker value=" << i << endl;
528  }
529 @@ -567,7 +567,8 @@
530  {
531    f.set_encoding(msb, type);
532    switch(type) {
533 -  case LataDBDataType::INT32: f.read((LataDBInt32*) 0, size); break;
534 +  case LataDBDataType::INT32:
535 +  case LataDBDataType::INT64: f.read((LataDBInt32*) 0, size); break;
536    case LataDBDataType::REAL32: f.read((float*) 0, size); break;
537    default:
538      Journal() << "Internal error: bloc read skip not code for this type" << endl;
539 @@ -592,14 +593,14 @@
540  }
541  
542  void bloc_write(LataDataFile & f, LataDBDataType::MSB msb, LataDBDataType::Type type,
543 -                const ArrOfInt & tab, int columns)
544 +                const ArrOfInt & tab, long columns)
545  {
546    f.set_encoding(msb, type);
547    f.write(tab.addr(), tab.size_array(), columns);
548  }
549  
550  void bloc_write(LataDataFile & f, LataDBDataType::MSB msb, LataDBDataType::Type type,
551 -                const ArrOfFloat & tab, int columns)
552 +                const ArrOfFloat & tab, long columns)
553  {
554    f.set_encoding(msb, type);
555    f.write(tab.addr(), tab.size_array(), columns);
556 @@ -812,7 +813,7 @@
557    param = strtoll(s, &errorptr, 0 /* base 10 par defaut */);
558    if (errno || *errorptr != 0) {
559      Journal() << "LataDB::read_master_file error: " << err_msg << endl
560 -              << "Error converting a string to type long int : string = " << s << endl;
561 +              << "Error converting a string to type long long : string = " << s << endl;
562      throw(LataDBError(LataDBError::READ_ERROR));
563    }
564  }
565 @@ -852,10 +853,10 @@
566  
567    a faire extraire pour de vrai les differents mots de motlu
568    Nom motlu2(tmp);
569 -  int nb_comp=1;
570 +  long nb_comp=1;
571    {
572      const char *s = tmp;
573 -    int p=0;
574 +    long p=0;
575      while ( ((*s) != 0))
576        {
577          if ((*s) == (','))
578 @@ -872,10 +873,10 @@
579    param=Noms(nb_comp);
580    {
581      const char *s=motlu2;
582 -    for (int i=0;i<nb_comp;i++)
583 +    for (long i=0;i<nb_comp;i++)
584        {
585          
586 -        int j=motlu2.find(",");
587 +        long j=motlu2.find(",");
588          if (j==-1) j=0;
589          param[i]=(s+j);
590          cerr<<param[i]<<endl;
591 @@ -908,7 +909,7 @@
592  }
593  
594  // We update only fields found in the string
595 -// A string can contain both an int type and a float type: we get both in int_type and float_type
596 +// A string can contain both an long type and a float type: we get both in int_type and float_type
597  static void read_format_string(const Motcle & n, LataDBDataType & data_type, 
598                                 LataDBDataType::Type & int_type,
599                                 LataDBDataType::Type & float_type)
600 @@ -1104,7 +1105,7 @@
601    software_id_ = s; 
602  }
603  
604 -int is_med(const char* filename)
605 +long is_med(const char* filename)
606  {
607    Motcle motcle_nom_fic(filename);
608    
609 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDB.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDB.h
610 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDB.h 2020-03-23 22:18:49.000000000 +0100
611 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDB.h      2020-12-22 12:06:26.192148414 +0100
612 @@ -124,7 +124,7 @@
613    Field_UName();
614    Field_UName(const char *domain_name, const char *field_name, const char *loc);
615    Field_UName(const Field_UName &);
616 -  int operator==(const Field_UName &) const;
617 +  long operator==(const Field_UName &) const;
618    Field_UName & operator=(const Field_UName &);
619    Nom build_string() const;
620    const Motcle & get_localisation() const { return loc_; }
621 @@ -153,7 +153,7 @@
622    // Field name (without localisation spec)
623    Nom name_;
624    // Where is it ?
625 -  int timestep_;
626 +  long timestep_;
627    // Filename containing the data
628    // Special names: memory_buffer_file() => data stored in the LataDB memory buffer.
629    Nom filename_;
630 @@ -239,7 +239,7 @@
631    // Third line in the .lata file
632    Nom software_id_;
633  
634 -  LataDBDataType default_type_float() const; // Everything same as int, but type_=default_float_type_
635 +  LataDBDataType default_type_float() const; // Everything same as long, but type_=default_float_type_
636    LataDBDataType default_type_int_;
637    LataDBDataType::Type default_float_type_;
638  
639 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDBmed.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDBmed.h
640 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataDBmed.h      2020-03-23 22:18:49.000000000 +0100
641 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataDBmed.h   2020-12-22 12:06:26.193148412 +0100
642 @@ -81,7 +81,7 @@
643        case MED_SEG2:
644          type_elem="Segment"; break;
645        default:
646 -        Cerr<<"type_geo " << (int)type_geo <<" is not a supported element."<<finl;
647 +        Cerr<<"type_geo " << (long)type_geo <<" is not a supported element."<<finl;
648         throw;
649          break;
650        }
651 @@ -128,12 +128,12 @@
652  
653  extern med_geometry_type typmai3[MED_N_CELL_FIXED_GEO];
654  
655 -void latadb_get_info_mesh_med(const char* filename,const char* meshname,med_geometry_type& type_geo,int& ncells,int& nnodes,int& spacedim, int &nbcomp,int& is_structured, std::vector<int>& NIJK)
656 +void latadb_get_info_mesh_med(const char* filename,const char* meshname,med_geometry_type& type_geo,long& ncells,long& nnodes,long& spacedim, long &nbcomp,long& is_structured, std::vector<long>& NIJK)
657  {
658      is_structured=0;
659 -  int meshDim, i;
660 +  long meshDim, i;
661    try {
662 -  std::vector< std::vector< std::pair<INTERP_KERNEL::NormalizedCellType,int> > > res = MEDCoupling::GetUMeshGlobalInfo(filename, meshname, meshDim, spacedim, nnodes);
663 +  std::vector< std::vector< std::pair<INTERP_KERNEL::NormalizedCellType,long> > > res = MEDCoupling::GetUMeshGlobalInfo(filename, meshname, meshDim, spacedim, nnodes);
664    
665  
666    // on prend que la dimension la plus grande et on verifie que l'on a qu'un type elt 
667 @@ -154,7 +154,7 @@
668        //on est force de lire le maillage pour avoir le bon nombre de cellules  
669        MEDCoupling::MEDCouplingUMesh * mesh=  MEDCoupling::ReadUMeshFromFile(filename,meshname);
670        ncells = mesh->getNumberOfCells();
671 -      const int *idx = mesh->getNodalConnectivityIndex()->getConstPointer();
672 +      const long *idx = mesh->getNodalConnectivityIndex()->getConstPointer();
673        for (i = 0, nbcomp = 0; i < ncells; i++) if (nbcomp < idx[i + 1] - idx[i] - 1) nbcomp = idx[i + 1] - idx[i] - 1;
674        mesh->decrRef();
675      }
676 @@ -166,7 +166,7 @@
677      // No UMesh try CMesh
678        MEDCoupling::MEDCouplingMesh* mesh=  MEDCoupling::ReadMeshFromFile(filename, meshname);
679        /* 
680 -        type_geo,int& ncells,int& nnodes,int& spacedim, int &nbcomp
681 +        type_geo,long& ncells,long& nnodes,long& spacedim, long &nbcomp
682         */
683        MEDCoupling::MEDCouplingCMesh* cmesh = dynamic_cast<MEDCoupling::MEDCouplingCMesh*>(mesh);
684        spacedim=cmesh-> getSpaceDimension() ;
685 @@ -229,17 +229,17 @@
686    
687    vector<double> times;
688    LataDBTimestep  table; 
689 -  int first=1;
690 +  long first=1;
691    
692 -  for (int i=0;i<geoms.size();i++)
693 +  for (long i=0;i<geoms.size();i++)
694      {
695        LataDBGeometry dom;
696        dom.timestep_ = timesteps_.size()-1;
697        dom.name_=geoms[i];
698        med_geometry_type type_geo;
699 -      int ncells,nnodes,spacedim, nbcomp;
700 -      int is_structured;
701 -      std::vector<int> NIJK;
702 +      long ncells,nnodes,spacedim, nbcomp;
703 +      long is_structured;
704 +      std::vector<long> NIJK;
705        latadb_get_info_mesh_med(filename,geoms[i].c_str(),type_geo,ncells,nnodes,spacedim,nbcomp,is_structured,NIJK);
706              
707        dom.elem_type_=latadb_name_from_type_geo(type_geo);
708 @@ -261,7 +261,7 @@
709        elem.size_=ncells;
710        elem.datatype_ = default_type_float(); // ??
711  
712 -      int dim,ff,ef;
713 +      long dim,ff,ef;
714        get_element_data(dom.elem_type_, dim, elem.nb_comp_, ff, ef);
715        if (elem.nb_comp_ == -1) elem.nb_comp_ = nbcomp;
716        
717 @@ -310,7 +310,7 @@
718    fields= MEDCoupling::GetAllFieldNamesOnMesh(filename,dom.name_.getString());
719    
720  
721 -  for (int i=0;i<fields.size();i++)
722 +  for (long i=0;i<fields.size();i++)
723      {
724        LataDBField som;
725        som.name_ = fields[i];
726 @@ -330,7 +330,7 @@
727        // cerr<<"field " <<fields[i]<< " "<< meshname<<" ";
728        vector< MEDCoupling::TypeOfField > ltypes=MEDCoupling::GetTypesOfField(filename,meshname.getString(),fields[i].c_str());
729        //if (ltypes.size()!=1) throw;
730 -      for (int t=0;t<ltypes.size();t++)
731 +      for (long t=0;t<ltypes.size();t++)
732        {
733        switch (ltypes[t])
734         {
735 @@ -372,8 +372,8 @@
736        {
737         if (ltypes.size()>1)
738           {
739 -           vector<pair< int, int > > iters= MEDCoupling::GetFieldIterations(ltypes[t],filename,meshname.getString(),fields[i].c_str());
740 -           for (int iter=0;iter<iters.size();iter++)
741 +           vector<pair< long, long > > iters= MEDCoupling::GetFieldIterations(ltypes[t],filename,meshname.getString(),fields[i].c_str());
742 +           for (long iter=0;iter<iters.size();iter++)
743               {
744                 double t= MEDCoupling::GetTimeAttachedOnFieldIteration(filename,fields[i].c_str(),iters[iter].first,iters[iter].second);
745                 if (first==1)
746 @@ -394,8 +394,8 @@
747           }
748         else
749           {
750 -           vector<pair<pair<int,int>,double> > vtimes=MEDCoupling::GetAllFieldIterations(filename,/*meshname,*/fields[i].c_str());
751 -           for (int it=0;it<vtimes.size();it++)
752 +           vector<pair<pair<long,long>,double> > vtimes=MEDCoupling::GetAllFieldIterations(filename,/*meshname,*/fields[i].c_str());
753 +           for (long it=0;it<vtimes.size();it++)
754               {
755                 
756                 double t=vtimes[it].second;
757 @@ -421,17 +421,17 @@
758      }
759      }
760    if (times.size()>0)
761 -    for (int i=0;i<times.size();i++)
762 +    for (long i=0;i<times.size();i++)
763      {
764        
765        //LataDBTimestep & t = timesteps_.add(table);
766        LataDBTimestep& t = timesteps_.add(LataDBTimestep());
767        t.time_=times[i];
768 -      for (int f=0;f<table.fields_.size();f++)
769 +      for (long f=0;f<table.fields_.size();f++)
770         add(i+1,table.fields_[f]);
771      
772      }
773 -  for (int i=0;i<times.size()*0;i++)
774 +  for (long i=0;i<times.size()*0;i++)
775      cerr<<" time "<<times[i]<<endl;
776  }
777  
778 @@ -452,8 +452,8 @@
779        MEDCoupling::MEDCouplingUMesh * mesh=  MEDCoupling::ReadUMeshFromFile(fld.filename_.getString(),fld.geometry_.getString());
780        const  MEDCoupling::DataArrayDouble* coords=mesh->getCoords();
781        data->resize(fld.size_,fld.nb_comp_);
782 -      for (int i=0;i<fld.size_;i++)
783 -       for (int j=0;j<fld.nb_comp_;j++)
784 +      for (long i=0;i<fld.size_;i++)
785 +       for (long j=0;j<fld.nb_comp_;j++)
786           {
787             (*data)(i,j)=coords->getIJ(i,j);
788           }
789 @@ -468,15 +468,15 @@
790        ArrOfInt filter=renum_conn(type);
791        MEDCoupling::MEDCouplingUMesh * mesh=  MEDCoupling::ReadUMeshFromFile(fld.filename_.getString(),fld.geometry_.getString());
792        const  MEDCoupling::DataArrayInt *elems = mesh->getNodalConnectivity(), *idx = mesh->getNodalConnectivityIndex();
793 -      const int *ptr_elems=elems->getConstPointer(), *ptr_idx = idx->getConstPointer();
794 +      const long *ptr_elems=elems->getConstPointer(), *ptr_idx = idx->getConstPointer();
795        data->resize(fld.size_,fld.nb_comp_);
796 -      int compt=0;
797 -      for (int i=0;i<fld.size_;i++)
798 +      long compt=0;
799 +      for (long i=0;i<fld.size_;i++)
800        {
801            compt++;
802 -          for (int j=0;j<fld.nb_comp_;j++)
803 +          for (long j=0;j<fld.nb_comp_;j++)
804            {
805 -              int reel = j + ptr_idx[i] + 1 < ptr_idx[i + 1];
806 +              long reel = j + ptr_idx[i] + 1 < ptr_idx[i + 1];
807                (*data)(i,filter.size_array()>0 ? filter[j] : j) = reel ? ptr_elems[compt] + 1 : 0;
808                compt += reel;
809            }
810 @@ -488,7 +488,7 @@
811        MEDCoupling::MEDCouplingMesh * mesh=  MEDCoupling::ReadMeshFromFile(fld.filename_.getString(),fld.geometry_.getString());
812        data->resize(fld.size_,fld.nb_comp_);
813        MEDCoupling::MEDCouplingCMesh* cmesh = dynamic_cast<MEDCoupling::MEDCouplingCMesh*>(mesh);
814 -      int dir;
815 +      long dir;
816        if (fld.name_=="SOMMETS_IJK_I")
817            dir=0;
818        else  if (fld.name_=="SOMMETS_IJK_J")
819 @@ -498,8 +498,8 @@
820        else
821            abort();
822        const MEDCoupling::DataArrayDouble* coords=cmesh->getCoordsAt(dir);
823 -      for (int i=0;i<fld.size_;i++)
824 -       for (int j=0;j<fld.nb_comp_;j++)
825 +      for (long i=0;i<fld.size_;i++)
826 +       for (long j=0;j<fld.nb_comp_;j++)
827           {
828             (*data)(i,j)=coords->getIJ(i,j);
829           }
830 @@ -519,11 +519,11 @@
831        fieldname+="_";
832        fieldname+=fld.geometry_;
833        
834 -      int ok=0;
835 +      long ok=0;
836     
837        vector<string> fields= MEDCoupling::GetAllFieldNamesOnMesh(fld.filename_.getString(),fld.geometry_.getString());
838        
839 -      for (int f=0;f<fields.size();f++)
840 +      for (long f=0;f<fields.size();f++)
841         {
842           if (fieldname==fields[f].c_str())
843             {
844 @@ -535,10 +535,10 @@
845         {
846           fieldname=fld.name_;
847         }
848 -      vector<pair<pair<int,int>,double> > vtimes=MEDCoupling::GetAllFieldIterations(fld.filename_.getString(),fieldname.getString());
849 +      vector<pair<pair<long,long>,double> > vtimes=MEDCoupling::GetAllFieldIterations(fld.filename_.getString(),fieldname.getString());
850  
851 -      int it=fld.timestep_-1;
852 -      pair <int,int> iter(fld.timestep_-1,-1);
853 +      long it=fld.timestep_-1;
854 +      pair <long,long> iter(fld.timestep_-1,-1);
855        if (fld.timestep_==1) it=0;
856        //Cerr<<iter.first <<" 00 "<<vtimes.size()<<finl;
857      
858 @@ -572,9 +572,9 @@
859         {
860           assert(field->getNumberOfComponents()==fld.nb_comp_);
861           const double* ptr=values->getConstPointer();
862 -         for (int i=0;i<fld.size_;i++)
863 +         for (long i=0;i<fld.size_;i++)
864             {
865 -             for (int j=0;j<fld.nb_comp_;j++)
866 +             for (long j=0;j<fld.nb_comp_;j++)
867                 {                
868                   (*data)(i,j)=ptr[i*fld.nb_comp_+j];
869                 }
870 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataFilter.C ParaView/Utilities/VisItBridge/databases/readers/Lata/LataFilter.C
871 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataFilter.C     2020-03-23 22:18:49.000000000 +0100
872 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataFilter.C  2020-12-22 12:06:26.193148412 +0100
873 @@ -56,7 +56,7 @@
874    char *errorptr = 0;
875    entier x = strtol(ptr+1, &errorptr, 0 /* base 10 par defaut */);
876    if (errno || *errorptr != 0) {
877 -    Journal() << "LataOptions error reading int parameter: " << s << endl;
878 +    Journal() << "LataOptions error reading long parameter: " << s << endl;
879      throw;
880    }
881    return x;
882 @@ -521,7 +521,7 @@
883      data.displayed_name_ = lata_geom_name;
884      
885      Nom separ("boundaries_");
886 -    int m=data.displayed_name_.find(separ);
887 +    long m=data.displayed_name_.find(separ);
888      if (m>0)
889        {
890         const Nom& name= data.displayed_name_;
891 @@ -990,17 +990,17 @@
892  
893  void LataOptions::extract_path_basename(const char * s, Nom & path_prefix, Nom & basename)
894  {
895 -  int i;
896 -  for (i=(int)strlen(s)-1;i>=0;i--)
897 +  long i;
898 +  for (i=(long)strlen(s)-1;i>=0;i--)
899      if ((s[i]==PATH_SEPARATOR) ||(s[i]=='\\'))
900        break;
901    path_prefix = "";
902 -  int j;
903 +  long j;
904    for (j = 0; j <= i; j++)
905      path_prefix += Nom(s[j]);
906    
907    // Parse basename : if extension given, remove it
908 -  int n = (int)strlen(s);
909 +  long n = (long)strlen(s);
910    if (n > 5 && strcmp(s+n-5,".lata") == 0)
911      n -= 5;
912    basename = "";
913 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataFilter.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataFilter.h
914 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataFilter.h     2020-03-23 22:18:49.000000000 +0100
915 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataFilter.h  2020-12-22 12:06:26.194148410 +0100
916 @@ -62,19 +62,19 @@
917  
918    bool   reconnect;  // Do we want to reconnect multiblock meshes
919    float  reconnect_tolerance;
920 -  int regularize_polyedre ; // if 1 Treate polyedre as poyledre extruder
921 -  int    regularize;    // Do we want to force regularize the domain ie convert the mesh to a structured ijk (not necessary except for dual-mesh vdf)
922 +  long regularize_polyedre ; // if 1 Treate polyedre as poyledre extruder
923 +  long    regularize;    // Do we want to force regularize the domain ie convert the mesh to a structured ijk (not necessary except for dual-mesh vdf)
924                          // special value 2 means "regularize if faces present and vdf"
925 -  int    extend_domain; // Extend the regularized domaine by n layers of cells
926 +  long    extend_domain; // Extend the regularized domaine by n layers of cells
927    float  regularize_tolerance;
928    bool   invalidate; // invalidate unused positions and connections;
929    bool   load_virtual_elements; // Do we want to extend the loaded mesh subblocks with a layer of virtual elements
930    bool   export_fields_at_faces_; // Should we show these fields in exportable fields
931    
932    // When loading ijk regular meshes, virtually create this number of blocks in the K direction:
933 -  int    ijk_mesh_nb_parts_;
934 +  long    ijk_mesh_nb_parts_;
935    // When loading ijk regular meshes, merge N layers of virtual elements (default=1)
936 -  int    ijk_virt_layer;
937 +  long    ijk_virt_layer;
938  
939    bool   user_fields_; //activate user fields ?
940  
941 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataStructures.C ParaView/Utilities/VisItBridge/databases/readers/Lata/LataStructures.C
942 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataStructures.C 2020-03-23 22:18:49.000000000 +0100
943 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataStructures.C      2020-12-22 12:06:26.194148410 +0100
944 @@ -41,7 +41,7 @@
945    case LataField_base::ELEM: n = nb_elements(); break;
946    case LataField_base::FACES: n = nb_faces(); break;
947    default:
948 -    Journal() << "Invalid localisation " << (int) loc << " in Domain::nb_items" << endl;
949 +    Journal() << "Invalid localisation " << (long) loc << " in Domain::nb_items" << endl;
950      throw;
951    }
952    return n;
953 @@ -58,11 +58,11 @@
954    case LataField_base::ELEM: n = decal_elements_lata_; break;
955    case LataField_base::FACES: n = decal_faces_lata_; break;
956    default:
957 -    Journal() << "Invalid localisation " << (int) loc << " in Domain::lata_block_offset" << endl;
958 +    Journal() << "Invalid localisation " << (long) loc << " in Domain::lata_block_offset" << endl;
959      throw;
960    }
961    if (n < 0) {
962 -    Journal() << "Error: lata_block_offset not set for localisation " << (int) loc << endl;
963 +    Journal() << "Error: lata_block_offset not set for localisation " << (long) loc << endl;
964      throw;
965    }
966    return n;
967 @@ -76,7 +76,7 @@
968    case LataField_base::ELEM: decal_elements_lata_ = n; break;
969    case LataField_base::FACES: decal_faces_lata_ = n; break;
970    default:
971 -    Journal() << "Invalid localisation " << (int) loc << " in Domain::set_lata_block_offset" << endl;
972 +    Journal() << "Invalid localisation " << (long) loc << " in Domain::set_lata_block_offset" << endl;
973      throw;
974    }
975  }
976 @@ -89,11 +89,11 @@
977    const entier nb_som_elem = elements_.dimension(1);
978    const double facteur = 1. / (double) nb_som_elem;
979    double tmp[3];
980 -  for (int i = 0; i < nb_elem; i++) {
981 -    int j, k;
982 +  for (long i = 0; i < nb_elem; i++) {
983 +    long j, k;
984      tmp[0] = tmp[1] = tmp[2] = 0.;
985      for (j = 0; j < nb_som_elem; j++) {
986 -      int som = elements_(i, j);
987 +      long som = elements_(i, j);
988        for (k = 0; k < loop_max(dim, 3); k++) {
989          tmp[k] += nodes_(som, k);
990          break_loop(k, dim);
991 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataStructures.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataStructures.h
992 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataStructures.h 2020-03-23 22:18:49.000000000 +0100
993 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataStructures.h      2020-12-22 12:06:26.194148410 +0100
994 @@ -43,14 +43,14 @@
995  class Domain_Id
996  {
997  public:
998 -  Domain_Id(const char * name = "??", int t = 0, int block = -1) :
999 +  Domain_Id(const char * name = "??", long t = 0, long block = -1) :
1000      name_(name), timestep_(t), block_(block) {};
1001    // Domain name
1002    Nom name_;
1003    // At which timestep (needed for dynamic domains)
1004 -  int timestep_;
1005 +  long timestep_;
1006    // Which block of the parallel computation ? -1 => all blocks
1007 -  int block_;
1008 +  long block_;
1009  };
1010  
1011  // Description: Field_Id is what you need to identify the content of a
1012 @@ -60,11 +60,11 @@
1013  {
1014  public:
1015    Field_Id() : timestep_(0) {};
1016 -  Field_Id(const Field_UName & uname, int timestep, int block) :
1017 +  Field_Id(const Field_UName & uname, long timestep, long block) :
1018      timestep_(timestep), block_(block), uname_(uname)  {};
1019    
1020 -  int         timestep_;
1021 -  int         block_;
1022 +  long         timestep_;
1023 +  long         block_;
1024    Field_UName uname_;
1025  
1026    operator Domain_Id() const { return Domain_Id(uname_.get_geometry(), timestep_, block_); }
1027 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Lata_tools.C ParaView/Utilities/VisItBridge/databases/readers/Lata/Lata_tools.C
1028 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Lata_tools.C     2020-03-23 22:18:49.000000000 +0100
1029 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/Lata_tools.C  2020-12-22 12:06:26.194148410 +0100
1030 @@ -36,7 +36,7 @@
1031  #include <string.h>
1032  #include <stdlib.h>
1033  
1034 -static int journal_level = 0;
1035 +static long journal_level = 0;
1036  
1037  void set_Journal_level(entier level)
1038  {
1039 @@ -89,17 +89,17 @@
1040  
1041  BigEntier memory_size(const ArrOfBit & tab)
1042  {
1043 -  return ((BigEntier)sizeof(tab)) + ((BigEntier)tab.size_array()) * sizeof(int) / 32; 
1044 +  return ((BigEntier)sizeof(tab)) + ((BigEntier)tab.size_array()) * sizeof(long) / 32; 
1045  }
1046  
1047  void split_path_filename(const char *s, Nom & path, Nom & filename)
1048  {
1049 -  int i;
1050 -  for (i=(int)strlen(s)-1;i>=0;i--)
1051 +  long i;
1052 +  for (i=(long)strlen(s)-1;i>=0;i--)
1053      if ((s[i]==PATH_SEPARATOR) || (s[i]=='\\'))
1054        break;
1055    path = "";
1056 -  int j;
1057 +  long j;
1058    for (j = 0; j <= i; j++)
1059      path += Nom(s[j]);
1060    
1061 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.C ParaView/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.C
1062 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.C       2020-03-23 22:18:49.000000000 +0100
1063 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.C    2020-12-22 12:06:26.195148408 +0100
1064 @@ -32,7 +32,7 @@
1065  
1066  typedef struct {
1067    const char * name;
1068 -  int shape; // Vector size (-1 => dimension of the problem)
1069 +  long shape; // Vector size (-1 => dimension of the problem)
1070  } StdComponents;
1071  
1072  // COMPOSANTES EN MAJUSCULES !!!!!
1073 @@ -72,7 +72,7 @@
1074      // Empty label means end of the table
1075    };
1076  
1077 -int latav1_component_shape(const Motcle & compo)
1078 +long latav1_component_shape(const Motcle & compo)
1079  {
1080    entier i = 0;
1081    while (std_components[i].name[0] != 0) {
1082 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.h
1083 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.h       2020-03-23 22:18:49.000000000 +0100
1084 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataV1_field_definitions.h    2020-12-22 12:06:26.195148408 +0100
1085 @@ -32,4 +32,4 @@
1086  // (separated from LataDB.cpp so that changes in this file are
1087  //  easily identified)
1088  class Motcle;
1089 -int latav1_component_shape(const Motcle & compo);
1090 +long latav1_component_shape(const Motcle & compo);
1091 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataVector.h ParaView/Utilities/VisItBridge/databases/readers/Lata/LataVector.h
1092 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LataVector.h     2020-03-23 22:18:49.000000000 +0100
1093 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LataVector.h  2020-12-22 12:06:26.195148408 +0100
1094 @@ -41,19 +41,19 @@
1095    LataVector(const LataVector<C> & x) : n_(0), data_(0) { operator=(x); }
1096    LataVector(entier n) : n_(0), data_(0) { for (entier i=0; i<n; i++) add(); }
1097    ~LataVector() { reset(); }
1098 -  void reset() { for (int i=0; i<n_; i++) { delete data_[i]; }; delete[] data_; n_ = 0; data_ = 0; }
1099 +  void reset() { for (long i=0; i<n_; i++) { delete data_[i]; }; delete[] data_; n_ = 0; data_ = 0; }
1100    const C & operator[](entier i) const { assert(i>=0 && i<n_); return *(data_[i]); }
1101    C & operator[](entier i) { assert(i>=0 && i<n_); return *(data_[i]); }
1102    C & add(const C & item) { return add_item(new C(item)); }
1103    C & add() { return add_item(new C); }
1104    entier size() const { return n_; }
1105    entier rang(const C & c) const { for (entier i = 0; i < n_; i++) if (*(data_[i]) == c) return i; return -1; }
1106 -  LataVector<C> & operator=(const LataVector<C> & x) { reset(); for (int i=0; i<x.n_; i++) add(x[i]); return *this; }
1107 +  LataVector<C> & operator=(const LataVector<C> & x) { reset(); for (long i=0; i<x.n_; i++) add(x[i]); return *this; }
1108  private:
1109    C & add_item(C* added_item) {
1110      C** old = data_; 
1111      data_ = new C*[n_+1]; 
1112 -    for (int i=0; i<n_; i++) data_[i] = old[i]; 
1113 +    for (long i=0; i<n_; i++) data_[i] = old[i]; 
1114      delete[] old;
1115      data_[n_++] = added_item;
1116      return *added_item;
1117 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LmlReader.C ParaView/Utilities/VisItBridge/databases/readers/Lata/LmlReader.C
1118 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/LmlReader.C      2020-03-23 22:18:49.000000000 +0100
1119 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/LmlReader.C   2020-12-22 12:06:26.195148408 +0100
1120 @@ -114,7 +114,7 @@
1121        Journal(lmllevel) << "lml_reader: GRILLE " << geom.name_ << endl;
1122        is >> sommets.nb_comp_;
1123        {
1124 -       int tmp;
1125 +       long tmp;
1126         is >> tmp; 
1127         sommets.size_ = tmp; // size_ est long long...
1128        }
1129 @@ -160,12 +160,12 @@
1130          throw;
1131        }
1132        {
1133 -       int tmp;
1134 +       long tmp;
1135         is >> tmp; // size_ est long long...
1136         elements.size_ = tmp;
1137        }
1138        is >> motlu;
1139 -      int borne_index_min=0;
1140 +      long borne_index_min=0;
1141        if (motlu == "TETRA4") {
1142          lata_db.set_elemtype(tstep, elements.geometry_, "TETRAEDRE");
1143          elements.nb_comp_ = 4;
1144 @@ -229,7 +229,7 @@
1145        if (data_filename)
1146          lata_db.write_data(tstep, elements.uname_, elems);
1147      } else if (motlu == "FACE") {
1148 -      int n;
1149 +      long n;
1150        is >> n;
1151        if (!is.good())
1152          throw LataDBError(LataDBError::READ_ERROR);
1153 @@ -291,7 +291,7 @@
1154        if (!is.good())
1155          throw LataDBError(LataDBError::READ_ERROR);
1156        {
1157 -       int tmp;
1158 +       long tmp;
1159         is >> tmp;
1160         field.size_ = tmp; // long long convert
1161        }
1162 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Motcle.C ParaView/Utilities/VisItBridge/databases/readers/Lata/Motcle.C
1163 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Motcle.C 2020-03-23 22:18:49.000000000 +0100
1164 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/Motcle.C      2020-12-22 12:06:26.196148405 +0100
1165 @@ -34,8 +34,8 @@
1166  #include <string>
1167  Nom& Nom::majuscule()
1168  {
1169 -  const int n = longueur()-1;
1170 -  for (int i = 0; i < n; i++)
1171 +  const long n = longueur()-1;
1172 +  for (long i = 0; i < n; i++)
1173      {
1174        char c = s_[i];
1175        if (c >= 'a' && c <= 'z')
1176 @@ -54,7 +54,7 @@
1177  
1178  // opt=0 => comparaison des chaines completes
1179  // opt=1 => le debut de n1 doit etre egal a n2
1180 -int Motcle::strcmp_uppercase(const char *n1, const char *n2, int opt)
1181 +long Motcle::strcmp_uppercase(const char *n1, const char *n2, long opt)
1182  {
1183    entier i = 0;
1184    unsigned char c1, c2;
1185 @@ -76,17 +76,17 @@
1186    return delta;
1187  }
1188  
1189 -int Nom::debute_par(const char * s) const
1190 +long Nom::debute_par(const char * s) const
1191  {
1192 -  const int l1 = longueur()-1;
1193 -  const int l2 = (int)strlen(s);
1194 +  const long l1 = longueur()-1;
1195 +  const long l2 = (long)strlen(s);
1196    return (l1>=l2) ? (strncmp(s_.c_str(), s, l2) == 0) : 0;
1197  }
1198  
1199 -int Nom::finit_par(const char * s) const
1200 +long Nom::finit_par(const char * s) const
1201  {
1202 -  const int l1 = longueur()-1;
1203 -  const int l2 = (int)strlen(s);
1204 +  const long l1 = longueur()-1;
1205 +  const long l2 = (long)strlen(s);
1206    return (l1>=l2) ? (strncmp(s_.c_str()+(l1-l2), s, l2) == 0) : 0;
1207  }
1208  
1209 @@ -107,15 +107,15 @@
1210    return *this;
1211  }
1212  
1213 -int Motcle::debute_par(const char * s) const
1214 +long Motcle::debute_par(const char * s) const
1215  {
1216    return (strcmp_uppercase(s_.c_str(), s, 1) == 0);
1217  }
1218  
1219 -int Motcle::finit_par(const char * s) const
1220 +long Motcle::finit_par(const char * s) const
1221  {
1222 -  const int l1 = longueur()-1;
1223 -  const int l2 = (int)strlen(s);
1224 +  const long l1 = longueur()-1;
1225 +  const long l2 = (long)strlen(s);
1226    return (l1>=l2) ? (strcmp_uppercase(s_.c_str()+(l1-l2), s) == 0) : 0;
1227  }
1228  
1229 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Motcle.h ParaView/Utilities/VisItBridge/databases/readers/Lata/Motcle.h
1230 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/Motcle.h 2020-03-23 22:18:49.000000000 +0100
1231 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/Motcle.h      2020-12-22 12:06:26.196148405 +0100
1232 @@ -61,7 +61,7 @@
1233    {
1234      s_ = c;
1235    };
1236 -  Nom(int i)
1237 +  Nom(long i)
1238    {
1239      char s[30];
1240      sprintf(s, "%d", i);
1241 @@ -88,11 +88,11 @@
1242    {
1243      os << s_;
1244    }
1245 -  virtual int operator==(const char * s) const
1246 +  virtual long operator==(const char * s) const
1247    {
1248      return (s_ == s);
1249    }
1250 -  virtual int operator!=(const char * s) const
1251 +  virtual long operator!=(const char * s) const
1252    {
1253      return !operator==(s);
1254    }
1255 @@ -102,8 +102,8 @@
1256      return *this;
1257    }
1258    virtual entier find(const char * n) const;
1259 -  virtual int debute_par(const char * s) const;
1260 -  virtual int finit_par(const char * s) const;
1261 +  virtual long debute_par(const char * s) const;
1262 +  virtual long finit_par(const char * s) const;
1263    virtual Nom& prefix(const char * s);
1264    Nom&          majuscule();
1265  protected:
1266 @@ -118,11 +118,11 @@
1267    Motcle(const char * s) : Nom(s) {};
1268    Motcle(const Nom& n) : Nom(n) {};
1269    ~Motcle() {};
1270 -  int operator==(const char * s) const
1271 +  long operator==(const char * s) const
1272    {
1273      return (strcmp_uppercase(s_.c_str(), s) == 0);
1274    }
1275 -  int operator!=(const char * s) const
1276 +  long operator!=(const char * s) const
1277    {
1278      return !operator==(s);
1279    }
1280 @@ -131,10 +131,10 @@
1281      s_ += n;
1282      return *this;
1283    }
1284 -  int debute_par(const char * s) const;
1285 -  int finit_par(const char * s) const;
1286 +  long debute_par(const char * s) const;
1287 +  long finit_par(const char * s) const;
1288  
1289 -  static int strcmp_uppercase(const char * s1, const char * s2, int opt = 0);
1290 +  static long strcmp_uppercase(const char * s1, const char * s2, long opt = 0);
1291    virtual entier find(const char * n) const
1292    {
1293      return Nom(*this).majuscule().find(Nom(n).majuscule());
1294 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.C ParaView/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.C
1295 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.C   2020-03-23 22:18:49.000000000 +0100
1296 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.C        2020-12-22 12:06:26.196148405 +0100
1297 @@ -39,14 +39,14 @@
1298  {
1299  public:
1300    DX_stream() : os_to_cout_(0), os_(0) {};
1301 -  void init_cout(int is_ascii) 
1302 +  void init_cout(long is_ascii) 
1303    { 
1304      reset();
1305      os_to_cout_ = 1;
1306      ascii_ = is_ascii;
1307      os_ = &std::cout;
1308    }
1309 -  void init_file(const char *fname, int is_ascii)
1310 +  void init_file(const char *fname, long is_ascii)
1311    {
1312      reset();
1313      os_to_cout_ = 0;
1314 @@ -62,17 +62,17 @@
1315      os_to_cout_ = 0;
1316    }
1317    DX_stream & operator<<(const float f) { (*os_) << f; return *this; }
1318 -  DX_stream & operator<<(const int i) { (*os_) << i; return *this; }
1319 +  DX_stream & operator<<(const long i) { (*os_) << i; return *this; }
1320    DX_stream & operator<<(const char * s) { (*os_) << s; return *this; }
1321    DX_stream & operator<<(DX_stream & f(DX_stream &)) { return f(*this); }
1322  
1323 -  void write(char * ptr, int sz) { os_->write(ptr, sz); }
1324 +  void write(char * ptr, long sz) { os_->write(ptr, sz); }
1325    entier ok() { return os_ != 0; }
1326    entier ascii() { return ascii_; }
1327    std::ostream & stream() { return *os_; }
1328  protected:
1329 -  int os_to_cout_;
1330 -  int ascii_;
1331 +  long os_to_cout_;
1332 +  long ascii_;
1333    std::ostream *os_;
1334  };
1335  
1336 @@ -82,9 +82,9 @@
1337    return os; 
1338  }
1339  
1340 -void DX_write_vect(DX_stream & os, int dxobject, const ArrOfFloat & v)
1341 +void DX_write_vect(DX_stream & os, long dxobject, const ArrOfFloat & v)
1342  {
1343 -  const int places = v.size_array();
1344 +  const long places = v.size_array();
1345    os << "object " << dxobject << " class array" << endl;
1346    os << "type float rank 1 shape 1 items " << places << " ";
1347  
1348 @@ -93,16 +93,16 @@
1349      os.write((char*)v.addr(), sizeof(float) * places);
1350    } else {
1351      os << "ascii data follows" << endl;
1352 -    for (int i=0;i<places;i++) {
1353 +    for (long i=0;i<places;i++) {
1354        os << v[i] << " ";
1355        os << endl;
1356      }
1357    }
1358  }
1359 -void DX_write_vect(DX_stream & os, int dxobject, const FloatTab & v)
1360 +void DX_write_vect(DX_stream & os, long dxobject, const FloatTab & v)
1361  {
1362 -  const int places = v.dimension(0);
1363 -  const int shape  = v.dimension(1);
1364 +  const long places = v.dimension(0);
1365 +  const long shape  = v.dimension(1);
1366    os << "object " << dxobject << " class array" << endl;
1367    os << "type float rank 1 shape " << shape << " items " << places << " ";
1368  
1369 @@ -111,32 +111,32 @@
1370      os.write((char*)v.addr(), sizeof(float) * places * shape);
1371    } else {
1372      os << "ascii data follows" << endl;
1373 -    for (int i=0;i<places;i++) {
1374 -      for (int j=0;j<shape;j++)
1375 +    for (long i=0;i<places;i++) {
1376 +      for (long j=0;j<shape;j++)
1377          os << v(i, j) << " ";
1378        os << endl;
1379      }
1380    }
1381  }
1382  
1383 -void DX_write_vect(DX_stream & os, int dxobject, const IntTab & v)
1384 +void DX_write_vect(DX_stream & os, long dxobject, const IntTab & v)
1385  {
1386 -  if (sizeof(int) != 4) {
1387 -    Journal() << "Error DX_write_vect : int size != 32 bits" << endl;
1388 +  if (sizeof(long) != 4) {
1389 +    Journal() << "Error DX_write_vect : long size != 32 bits" << endl;
1390      throw OpenDXWriter::DXInternalError;
1391    }
1392 -  const int places = v.dimension(0);
1393 -  const int shape  = v.dimension(1);
1394 +  const long places = v.dimension(0);
1395 +  const long shape  = v.dimension(1);
1396    os << "object " << dxobject << " class array" << endl;
1397 -  os << "type int rank 1 shape " << shape << " items " << places << " ";
1398 +  os << "type long rank 1 shape " << shape << " items " << places << " ";
1399  
1400    if (!os.ascii()) {
1401      os << (mymachine_msb ? "msb ieee" : "lsb ieee") << " data follows" << endl;
1402 -    os.write((char*)v.addr(), sizeof(int) * places * shape);
1403 +    os.write((char*)v.addr(), sizeof(long) * places * shape);
1404    } else {
1405      os << "ascii data follows" << endl;
1406 -    for (int i=0;i<places;i++) {
1407 -      for (int j=0;j<shape;j++)
1408 +    for (long i=0;i<places;i++) {
1409 +      for (long j=0;j<shape;j++)
1410          os << v(i, j) << " ";
1411        os << endl;
1412      }
1413 @@ -163,7 +163,7 @@
1414    finish_geometry(); // reset geometry data
1415  }
1416  
1417 -void OpenDXWriter::init_cout(double time, int ascii)
1418 +void OpenDXWriter::init_cout(double time, long ascii)
1419  {
1420    reset();
1421    os_->init_cout(ascii);
1422 @@ -174,7 +174,7 @@
1423    DX_write_vect(*os_, dx_time_index_, t);
1424  }
1425  
1426 -void OpenDXWriter::init_file(double time, Nom & filename_, int ascii)
1427 +void OpenDXWriter::init_file(double time, Nom & filename_, long ascii)
1428  {
1429    reset();
1430    os_->init_file(filename_, ascii);
1431 @@ -319,7 +319,7 @@
1432    components_names_.add(n);
1433  }
1434  
1435 -entier OpenDXWriter::finish(int force_group)
1436 +entier OpenDXWriter::finish(long force_group)
1437  {
1438    DX_stream & os = *os_;
1439    finish_geometry();
1440 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.h ParaView/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.h
1441 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.h   2020-03-23 22:18:49.000000000 +0100
1442 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OpenDXWriter.h        2020-12-22 12:06:26.197148403 +0100
1443 @@ -48,32 +48,32 @@
1444  public:
1445    OpenDXWriter();
1446    ~OpenDXWriter();
1447 -  void init_cout(double time, int ascii = 0);
1448 -  void init_file(double time, Nom & filename_, int ascii = 0);
1449 +  void init_cout(double time, long ascii = 0);
1450 +  void init_file(double time, Nom & filename_, long ascii = 0);
1451  
1452    void write_geometry(const Domain & dom);
1453    void write_component(const LataField_base & field);
1454  
1455 -  entier finish(int force_group = 0);
1456 +  entier finish(long force_group = 0);
1457    enum DXErrors { DXInternalError };
1458  protected:
1459    void reset();
1460    void finish_geometry();
1461  
1462 -  int dx_time_index_;
1463 -  int index_counter_;
1464 +  long dx_time_index_;
1465 +  long index_counter_;
1466    // Indexes of all DXfield objects in the file (to build the final group)
1467    ArrOfInt fields_indexes_;
1468    // Names of the DXfields:
1469    Noms fields_names_;
1470  
1471    // Index of the nodes array of the last geometry
1472 -  int nodes_index_;
1473 +  long nodes_index_;
1474    // Index of the elements array of the last geometry
1475 -  int elements_index_;
1476 +  long elements_index_;
1477    // Index of these arrays:
1478 -  int invalid_positions_;
1479 -  int invalid_connections_;
1480 +  long invalid_positions_;
1481 +  long invalid_connections_;
1482    // Indexes of the components associated with the last geometry
1483    ArrOfInt components_indexes_;
1484    Noms components_names_;
1485 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorBoundary.C ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorBoundary.C
1486 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorBoundary.C       2020-03-23 22:18:49.000000000 +0100
1487 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorBoundary.C    2020-12-22 12:06:26.197148403 +0100
1488 @@ -50,7 +50,7 @@
1489        { 2, 3, 6, 7 },
1490        { 4, 5, 6, 7 } };
1491  
1492 -  int i, j;
1493 +  long i, j;
1494    switch(elt_type) {
1495    case Domain::tetra:
1496      ref_elem_face.resize(4,3);
1497 @@ -95,8 +95,8 @@
1498    op.src_element_.set_smart_resize(1);
1499    op.src_face_.set_smart_resize(1);
1500    op.src_nodes_.set_smart_resize(1);
1501 -  const int nb_nodes_per_face = element_faces.dimension(1);
1502 -  const int nb_faces_per_element = element_faces.dimension(0);
1503 +  const long nb_nodes_per_face = element_faces.dimension(1);
1504 +  const long nb_faces_per_element = element_faces.dimension(0);
1505  
1506    ArrOfInt one_face(nb_nodes_per_face);
1507    ArrOfInt adjacent_elements;
1508 @@ -114,8 +114,8 @@
1509    for (element_index = 0; element_index < nelem; element_index++) {
1510      for (local_face_index = 0; local_face_index < nb_faces_per_element; local_face_index++) {
1511        for (i = 0; i < nb_nodes_per_face; i++) {
1512 -        int local_node = element_faces(local_face_index, i);
1513 -        int node = src.elements_(element_index, local_node);
1514 +        long local_node = element_faces(local_face_index, i);
1515 +        long node = src.elements_(element_index, local_node);
1516          one_face[i] = node;
1517        }
1518        find_adjacent_elements(som_elem, one_face, adjacent_elements);
1519 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorDualMesh.C ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorDualMesh.C
1520 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorDualMesh.C       2020-03-23 22:18:49.000000000 +0100
1521 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorDualMesh.C    2020-12-22 12:06:26.197148403 +0100
1522 @@ -41,7 +41,7 @@
1523      Journal() << "Error in OperatorDualMesh::build_geometry: source domain has no faces data" << endl;
1524      throw;
1525    }
1526 -  const int max_nb_som_face = 3; // for tetrahedra
1527 +  const long max_nb_som_face = 3; // for tetrahedra
1528    if (src.elt_type_ != Domain::triangle && src.elt_type_ != Domain::tetra) {
1529      Journal() << "Error in OperatorDualMesh::build_geometry: cannot operate on unstructured mesh with this element type" << endl;
1530      throw;
1531 @@ -63,13 +63,13 @@
1532    const entier nb_som_face = src.faces_.dimension(1);
1533    const entier nb_som_elem = src.elements_.dimension(1);
1534    dest.elements_.resize(nb_elem * nb_faces_elem, nb_som_elem);
1535 -  int index = 0;
1536 -  for (int i = 0; i < nb_elem; i++) {
1537 -    const int central_node = nb_som + i;
1538 -    for (int j = 0; j < nb_faces_elem; j++) {
1539 -      const int face = src.elem_faces_(i, j);
1540 +  long index = 0;
1541 +  for (long i = 0; i < nb_elem; i++) {
1542 +    const long central_node = nb_som + i;
1543 +    for (long j = 0; j < nb_faces_elem; j++) {
1544 +      const long face = src.elem_faces_(i, j);
1545        dest.elements_(index, 0) = central_node;
1546 -      for (int k = 0; k < loop_max(nb_som_face, max_nb_som_face); k++) {
1547 +      for (long k = 0; k < loop_max(nb_som_face, max_nb_som_face); k++) {
1548          dest.elements_(index, k+1) = src.faces_(face, k);
1549          break_loop(k, nb_som_face);
1550        }
1551 @@ -99,11 +99,11 @@
1552    const entier nb_face_elem = src_domain.elem_faces_.dimension(1);
1553    const entier nb_comp = src.data_.dimension(1);
1554    dest.data_.resize(nb_elem * nb_face_elem, nb_comp);
1555 -  int index = 0;
1556 -  for (int i = 0; i < nb_elem; i++) {
1557 -    for (int j = 0; j < nb_face_elem; j++) {
1558 -      const int face = src_domain.elem_faces_(i, j);
1559 -      for (int k = 0; k < nb_comp; k++)
1560 +  long index = 0;
1561 +  for (long i = 0; i < nb_elem; i++) {
1562 +    for (long j = 0; j < nb_face_elem; j++) {
1563 +      const long face = src_domain.elem_faces_(i, j);
1564 +      for (long k = 0; k < nb_comp; k++)
1565          dest.data_(index, k) = src.data_(face, k);
1566        index++;
1567      }
1568 @@ -125,9 +125,9 @@
1569    for (entier i_dim = 0; i_dim < dim; i_dim++) {
1570      const ArrOfFloat & c1 = src.coord_[i_dim];
1571      ArrOfFloat & c2 = dest.coord_.add(ArrOfFloat());
1572 -    const int n = c1.size_array() - 1;
1573 +    const long n = c1.size_array() - 1;
1574      c2.resize_array(n*2+1);
1575 -    for (int i = 0; i < n; i++) {
1576 +    for (long i = 0; i < n; i++) {
1577        c2[i*2] = c1[i];
1578        c2[i*2+1] = (c1[i] + c1[i+1]) * 0.5;
1579      }
1580 @@ -137,20 +137,20 @@
1581    if (src.invalid_connections_.size_array() > 0) {
1582      dest.invalid_connections_.resize_array(dest.nb_elements());
1583      dest.invalid_connections_ = 0;
1584 -    int index = 0;
1585 +    long index = 0;
1586      
1587      const entier ni = dest.coord_[0].size_array()-1;
1588      const entier nj = dest.coord_[1].size_array()-1;
1589      const entier nk = (dim==3) ? (dest.coord_[2].size_array()-1) : 1;
1590      const entier ni_src = src.coord_[0].size_array() - 1;
1591      const entier nj_src = src.coord_[1].size_array() - 1;
1592 -    for (int k = 0; k < nk; k++) {
1593 -      const int k_src = k / 2;
1594 -      for (int j = 0; j < nj; j++) {
1595 -        const int j_src = j / 2;
1596 -        const int idx_source = (k_src * nj_src + j_src) * ni_src;
1597 -        for (int i = 0; i < ni; i++) {
1598 -          const int idx = idx_source + i / 2;
1599 +    for (long k = 0; k < nk; k++) {
1600 +      const long k_src = k / 2;
1601 +      for (long j = 0; j < nj; j++) {
1602 +        const long j_src = j / 2;
1603 +        const long idx_source = (k_src * nj_src + j_src) * ni_src;
1604 +        for (long i = 0; i < ni; i++) {
1605 +          const long idx = idx_source + i / 2;
1606            if (src.invalid_connections_[idx])
1607              dest.invalid_connections_.setbit(index);
1608            index++;
1609 @@ -175,7 +175,7 @@
1610    dest.localisation_ = LataField_base::ELEM;
1611    dest.nature_ = LataDBField::VECTOR;
1612    const entier dim = src_domain.dimension();
1613 -  int index = 0;
1614 +  long index = 0;
1615  
1616    // Loop on destination elements
1617    const entier ni = dest_domain.coord_[0].size_array()-1;
1618 @@ -184,15 +184,15 @@
1619    dest.data_.resize(ni*nj*nk, dim);
1620    const entier ni_src = src_domain.coord_[0].size_array();
1621    const entier nj_ni_src = src_domain.coord_[1].size_array() * ni_src;
1622 -  for (int k = 0; k < nk; k++) {
1623 -    const int k2 = k/2;
1624 -    const int k3 = (k+1)/2;
1625 -    for (int j = 0; j < nj; j++) {
1626 -      const int j2 = j/2;
1627 -      const int j3 = (j+1)/2;
1628 -      for (int i = 0; i < ni; i++) {
1629 -        const int i2 = i/2;
1630 -        const int i3 = (i+1)/2;
1631 +  for (long k = 0; k < nk; k++) {
1632 +    const long k2 = k/2;
1633 +    const long k3 = (k+1)/2;
1634 +    for (long j = 0; j < nj; j++) {
1635 +      const long j2 = j/2;
1636 +      const long j3 = (j+1)/2;
1637 +      for (long i = 0; i < ni; i++) {
1638 +        const long i2 = i/2;
1639 +        const long i3 = (i+1)/2;
1640          dest.data_(index, 0) = src.data_(IJK(i3,j2,k2), 0);
1641          dest.data_(index, 1) = src.data_(IJK(i2,j3,k2), 1);
1642          if (dim==3)
1643 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorFacesMesh.C ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorFacesMesh.C
1644 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorFacesMesh.C      2020-03-23 22:18:49.000000000 +0100
1645 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorFacesMesh.C   2020-12-22 12:06:26.197148403 +0100
1646 @@ -41,7 +41,7 @@
1647      Journal() << "Error in OperatorFacesMesh::build_geometry: source domain has no faces data" << endl;
1648      throw;
1649    }
1650 -  // const int max_nb_som_face = 3; // for tetrahedra
1651 +  // const long max_nb_som_face = 3; // for tetrahedra
1652    if (src.elt_type_ != Domain::triangle && src.elt_type_ != Domain::polygone && src.elt_type_ != Domain::tetra && src.elt_type_ != Domain::polyedre) {
1653      Journal() << "Error in OperatorFacesMesh::build_geometry: cannot operate on unstructured mesh with this element type" << endl;
1654      throw;
1655 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorRegularize.C ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorRegularize.C
1656 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/OperatorRegularize.C     2020-03-23 22:18:49.000000000 +0100
1657 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/OperatorRegularize.C  2020-12-22 12:06:26.198148401 +0100
1658 @@ -32,12 +32,12 @@
1659  
1660  #define verb_level 4
1661  
1662 -template<class T, class Tab> int search_in_ordered_vect(T x, const Tab & v, const T epsilon) {
1663 +template<class T, class Tab> long search_in_ordered_vect(T x, const Tab & v, const T epsilon) {
1664    if (!v.size_array())
1665      return -1;
1666 -  int i1=0;
1667 -  int i;
1668 -  int i2 = (int)v.size_array()-1;
1669 +  long i1=0;
1670 +  long i;
1671 +  long i2 = (long)v.size_array()-1;
1672    while (i1 != i2) {
1673      i = (i1+i2)/2;
1674      if (epsilon+ v[i] < x)
1675 @@ -56,9 +56,9 @@
1676  template<class T, class Tab>
1677  static void retirer_doublons(Tab & tab, const T epsilon)
1678  {
1679 -  int i = 0;
1680 -  int j;
1681 -  const int n = tab.size_array();
1682 +  long i = 0;
1683 +  long j;
1684 +  const long n = tab.size_array();
1685    T last_tab_i = -1e40;
1686    for (j = 0; j < n; j++) {
1687      const T x = tab[j];
1688 @@ -124,18 +124,18 @@
1689        throw;
1690      }
1691    }
1692 -  int i;
1693 +  long i;
1694    op.renum_nodes_.resize_array(nsom);
1695 -  int nb_som_ijk = 1;
1696 +  long nb_som_ijk = 1;
1697    for (i = 0; i < dim; i++) 
1698      nb_som_ijk *= nb_som_dir[i];
1699    IntTab ijk_indexes;
1700    ijk_indexes.resize(nsom, dim);
1701    for (i = 0; i < nsom; i++) {
1702      entier ijk_index = 0;
1703 -    for (int j = dim-1; j >= 0; j--) {
1704 +    for (long j = dim-1; j >= 0; j--) {
1705        const double x = src.nodes_(i,j);
1706 -      int index = search_in_ordered_vect(x, dest.coord_[j],op.tolerance_);
1707 +      long index = search_in_ordered_vect(x, dest.coord_[j],op.tolerance_);
1708        if (index < 0) {
1709          Journal() << "Error: coordinate (" << i << "," << j << ") = " << x << " not found in regularize" << endl
1710                    << "Try reducing regularize tolerance value (option regularize=epsilon)" << endl;
1711 @@ -148,26 +148,26 @@
1712      }
1713      op.renum_nodes_[i] = ijk_index;
1714    }
1715 -  const int max_index = max_array(nb_som_dir);
1716 -  int nb_elems_ijk = 1;
1717 +  const long max_index = max_array(nb_som_dir);
1718 +  long nb_elems_ijk = 1;
1719    for (i = 0; i < dim; i++)
1720      nb_elems_ijk *= nb_som_dir[i] - 1;
1721    dest.invalid_connections_.resize_array(nb_elems_ijk);
1722    dest.invalid_connections_ = 1; // Everything invalid by default
1723 -  const int nelem = src.elements_.dimension(0);
1724 -  const int nb_som_elem = src.elements_.dimension(1);
1725 +  const long nelem = src.elements_.dimension(0);
1726 +  const long nb_som_elem = src.elements_.dimension(1);
1727    op.renum_elements_.resize_array(nelem);
1728    // Pour chaque element, indice dans le maillage ijk du plus sommet le plus proche de l'origine
1729    // (pour les faces...)
1730    ArrOfInt idx_elem_som;
1731    idx_elem_som.resize_array(nelem);
1732 -  int min_index[3];
1733 +  long min_index[3];
1734    for (i = 0; i < nelem; i++) {
1735      min_index[0] = min_index[1] = min_index[2] = max_index;
1736 -    for (int j = 0; j < nb_som_elem; j++) {
1737 -      int node = src.elements_(i,j);
1738 -      for (int k = 0; k < loop_max(dim, 3); k++) {
1739 -        int idx = ijk_indexes(node, k);
1740 +    for (long j = 0; j < nb_som_elem; j++) {
1741 +      long node = src.elements_(i,j);
1742 +      for (long k = 0; k < loop_max(dim, 3); k++) {
1743 +        long idx = ijk_indexes(node, k);
1744          min_index[k] = (idx < min_index[k]) ? idx : min_index[k];
1745          break_loop(k,dim);
1746        }
1747 @@ -191,10 +191,10 @@
1748    }
1749    
1750    if (src.faces_ok()) {
1751 -    const int nfaces = src.faces_.dimension(0);
1752 +    const long nfaces = src.faces_.dimension(0);
1753      op.renum_faces_.resize_array(nfaces);
1754      op.renum_faces_ = -1;
1755 -    const int nb_elem_face = src.elem_faces_.dimension(1);
1756 +    const long nb_elem_face = src.elem_faces_.dimension(1);
1757      ArrOfInt delta_dir(dim);
1758      delta_dir[0] = 1;
1759      for (i = 1; i < dim; i++)
1760 diff -Nur ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/UserFields.C ParaView/Utilities/VisItBridge/databases/readers/Lata/UserFields.C
1761 --- ParaView.orig/Utilities/VisItBridge/databases/readers/Lata/UserFields.C     2020-03-23 22:18:49.000000000 +0100
1762 +++ ParaView/Utilities/VisItBridge/databases/readers/Lata/UserFields.C  2020-12-22 12:06:26.198148401 +0100
1763 @@ -346,7 +346,7 @@
1764      const IntTab & les_elem = dom.elements_;
1765      const entier n = les_elem.dimension(0);
1766      const entier m = les_elem.dimension(1);
1767 -    int i, j, k;
1768 +    long i, j, k;
1769      for ( i = 0; i < n; i++) {
1770        for (j = 0; j < m; j++) {
1771          entier som = les_elem(i,j);
1772 @@ -459,17 +459,17 @@
1773        Cerr<<" cas nn prevu"<<endl; 
1774        throw;
1775      }
1776 -  int nb_face=coords.dimension(0);
1777 +  long nb_face=coords.dimension(0);
1778    Vecteur3 normals[4];
1779    Vecteur3 edge[2],opp;
1780    edge[1].set(0,0,1);
1781 -  for (int n=0;n<nb_face;n++)
1782 +  for (long n=0;n<nb_face;n++)
1783      {
1784       
1785 -      int prem=0;
1786 +      long prem=0;
1787        if (n==0) prem=1;
1788 -      int compteur=0;
1789 -      for (int s=0;s<nb_face;s++)
1790 +      long compteur=0;
1791 +      for (long s=0;s<nb_face;s++)
1792          {
1793  
1794            if ((s!=n) && (s!=prem))
1795 @@ -492,8 +492,8 @@
1796      }
1797    // on a les 4 normals orientes vers l'interieur
1798    double max_pscal=-100;
1799 -  for (int n1=0;n1<nb_face;n1++)
1800 -    for (int n2=n1+1;n2<nb_face;n2++)
1801 +  for (long n1=0;n1<nb_face;n1++)
1802 +    for (long n2=n1+1;n2<nb_face;n2++)
1803        {
1804          double pscal=Vecteur3::produit_scalaire(normals[n1],normals[n2]);
1805          //min_pscal=pscal;
1806 @@ -539,11 +539,11 @@
1807      resu.data_.resize(n, nbcompo);
1808      
1809      const FloatTab& nodes_=dom.nodes_;
1810 -    int nb_som_elem=les_elem.dimension(1);
1811 +    long nb_som_elem=les_elem.dimension(1);
1812      DoubleTab coords(nb_som_elem,3);
1813 -    for ( int i = 0; i < n; i++) {
1814 -      for (int s=0;s<nb_som_elem;s++)
1815 -        for (int d=0;d<nodes_.dimension(1);d++)
1816 +    for ( long i = 0; i < n; i++) {
1817 +      for (long s=0;s<nb_som_elem;s++)
1818 +        for (long d=0;d<nodes_.dimension(1);d++)
1819            coords(s,d)=nodes_(les_elem(i,s),d);
1820        resu.data_(i, 0) = largest_angle_2(coords);
1821          
1822 @@ -587,16 +587,16 @@
1823      
1824      ArrOfFloat v1( nbcompo),v2(nbcompo);
1825      ArrOfDouble nor(nbcompo);
1826 -    for ( int i = 0; i < n; i++) {
1827 +    for ( long i = 0; i < n; i++) {
1828        // calcul de la normale
1829        entier som0 = les_elem(i,0);
1830        entier som1 = les_elem(i,1);
1831 -      for (int j=0;j<nbcompo;j++)
1832 +      for (long j=0;j<nbcompo;j++)
1833          v1[j]=nodes_(som1,j)-nodes_(som0,j);
1834        if (nbcompo==3)
1835          {
1836            entier som2 = les_elem(i,2);
1837 -          for (int j=0;j<nbcompo;j++)
1838 +          for (long j=0;j<nbcompo;j++)
1839              v2[j]=nodes_(som2,j)-nodes_(som0,j);
1840            
1841            nor[0]=v1[1]*v2[2]-v1[2]*v2[1];
1842 @@ -611,7 +611,7 @@
1843            nor[1]=-v1[0];
1844            
1845          }
1846 -      for (int k = 0; k < nbcompo; k++) {
1847 +      for (long k = 0; k < nbcompo; k++) {
1848          resu.data_(i, k) = nor[k];
1849        }
1850         
1851 @@ -756,11 +756,11 @@
1852    
1853    const entier nb_geometries = geoms.size();
1854    
1855 -  for (int i = 0; i < nb_geometries; i++) {
1856 +  for (long i = 0; i < nb_geometries; i++) {
1857      const LataGeometryMetaData data = filter.get_geometry_metadata(geoms[i]);
1858      
1859      // Si on a des faces, proposer la normale aux faces
1860 -    int topo_dim=data.dimension_;
1861 +    long topo_dim=data.dimension_;
1862      
1863      switch(data.element_type_) {
1864      case Domain::point:     topo_dim = 0; break;
1865 @@ -826,7 +826,7 @@
1866    //  (nb_fields_debut est le nombre de champs existant avant qu'on 
1867    //   commence a en ajouter dans le tableau fields_data)
1868  
1869 -  for (int i_in = 0; i_in < nb_fields_debut; i_in++) 
1870 +  for (long i_in = 0; i_in < nb_fields_debut; i_in++) 
1871      {
1872        // On cherche si le champ de temperature aux elements existe
1873        //  sur une geometrie IJK (Motcle permet d'ignorer majuscule/minuscule)
1874 @@ -902,9 +902,9 @@
1875    float volume() const { return dx_ * dy_ * dz_; }
1876  protected:
1877    void init(LataFilter & lata, const Domain_Id & id, entier demi_pas);
1878 -  FloatTab calculer_somme_dir(const FloatTab & src, const int dir) const;
1879 -  FloatTab annu_bord(const FloatTab & input, int epaisseur) const;
1880 -  int ijk_index(int i, int j, int k) const {
1881 +  FloatTab calculer_somme_dir(const FloatTab & src, const long dir) const;
1882 +  FloatTab annu_bord(const FloatTab & input, long epaisseur) const;
1883 +  long ijk_index(long i, long j, long k) const {
1884      if (i < 0)
1885        i = 0;
1886      else if (i >= nx_)
1887 @@ -924,10 +924,10 @@
1888    ArrOfBit invalid_connections_;
1889  
1890    entier demi_pas_;
1891 -  int pbDim_; // dimension
1892 -  int nx_;
1893 -  int ny_;
1894 -  int nz_;
1895 +  long pbDim_; // dimension
1896 +  long nx_;
1897 +  long ny_;
1898 +  long nz_;
1899    float dx_;
1900    float dy_;
1901    float dz_;
1902 @@ -967,19 +967,19 @@
1903    lata.release_geometry(dom);
1904  }
1905  
1906 -FloatTab FiltreSpatial::calculer_somme_dir(const FloatTab & src, const int dir) const
1907 +FloatTab FiltreSpatial::calculer_somme_dir(const FloatTab & src, const long dir) const
1908  {
1909 -  const int n = src.dimension(0);
1910 -  const int nb_compo = src.dimension(1);
1911 +  const long n = src.dimension(0);
1912 +  const long nb_compo = src.dimension(1);
1913    FloatTab tmp;
1914    tmp.resize(n, nb_compo);
1915  
1916 -  int index_resu = 0;
1917 -  for (int k = 0; k < nz_; k++) {
1918 -    for (int j = 0; j < ny_; j++) {
1919 -      for (int i = 0; i < nx_; i++) {
1920 -        for (int count = -demi_pas_; count <= demi_pas_; count++) {
1921 -          int index;
1922 +  long index_resu = 0;
1923 +  for (long k = 0; k < nz_; k++) {
1924 +    for (long j = 0; j < ny_; j++) {
1925 +      for (long i = 0; i < nx_; i++) {
1926 +        for (long count = -demi_pas_; count <= demi_pas_; count++) {
1927 +          long index;
1928            switch(dir) {
1929            case 0: index = ijk_index(i+count, j, k); break;
1930            case 1: index = ijk_index(i, j+count, k); break;
1931 @@ -992,7 +992,7 @@
1932              // element invalide !
1933            } else {
1934              // element ok !
1935 -            for (int compo = 0; compo < nb_compo; compo++)
1936 +            for (long compo = 0; compo < nb_compo; compo++)
1937                tmp(index_resu, compo) += src(index, compo);
1938            }
1939          }