Ticket #33903: patch-ml4.i.diff
File patch-ml4.i.diff, 877 bytes (added by paumard, 13 years ago) |
---|
-
ml4.i
diff -u ml4.i.orig ml4.i
old new func ml4write(file,data,varname,mode,endian=) 124 124 ncols=int(dims(3)); 125 125 } 126 126 127 if (structof(data)==long) { type='l'; } 127 tmp = data; // otherwise data may be swapped in place in endian='L' 128 129 // next line: fix from Thibaut Paumard for Debian. 130 if (structof(data)==long) { type='l'; tmp=int(tmp); } 128 131 else if (structof(data)==int) { type='l'; } 129 132 else if (structof(data)==float) { type='r'; } 130 133 else if (structof(data)==double) { type='d'; } … … func ml4write(file,data,varname,mode,endian=) 132 135 else if (structof(data)==char) { type='b'; } 133 136 else error,"Unsupported type"; 134 137 135 tmp = data; // otherwise data may be swapped in place in endian='L'136 137 138 status = matout(file,varname,&tmp,nrows,ncols,type,mode,endian); 138 139 if (status) error,"write failed"; 139 140 }