#11042 octave: Adjustments for updated API in version 7

Minor adjustments in data access for octave version 7. Previously used and verified version is octave 4.
This commit is contained in:
Magne Sjaastad committed 2024-01-12 16:06:32 +01:00
1 parent d065c8e1e0
commit 3f3ced5af0
4 files changed
+22 -5

No files matched your search

+6 -1
View File
@@ -63,7 +63,12 @@ void getSelectedCells(int32NDArray& selectedCellInfo, const QString &hostName, q
return;
}
qint32* internalMatrixData = (qint32*)selectedCellInfo.fortran_vec()->mex_get_data();
#if OCTAVE_MAJOR_VERSION > 6
auto internalMatrixData = (qint32*)selectedCellInfo.fortran_vec();
#else
auto internalMatrixData = (qint32*)selectedCellInfo.fortran_vec()->mex_get_data();
#endif
QStringList errorMessages;
if (!RiaSocketDataTransfer::readBlockDataFromSocket(&socket, (char*)(internalMatrixData), columnCount * byteCountForOneTimestep, errorMessages))
{