source:
issm/oecreview/Archive/12678-13393/ISSM-12861-12862.diff
Last change on this file was 13394, checked in by , 13 years ago | |
---|---|
File size: 3.0 KB |
-
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/shared/Alloc/alloc_module.cpp
1 /* \file alloc_module.h2 */3 4 5 #ifdef HAVE_CONFIG_H6 #include <config.h>7 #else8 #error "Cannot compile without HAVE_CONFIG_H symbol! run configure first!"9 #endif10 11 #include <stdio.h>12 #include <stdlib.h>13 14 #include "./alloc_module.h"15 #include "../Exceptions/exceptions.h"16 #include "../../include/include.h"17 #include "../../classes/objects/objects.h"18 19 void xdelete_module(Matrix** pv){20 21 if (pv && *pv){22 /*Actually, still get rid of internal Petsc matrix. Quick fix until Matlab handles C++23 * correctly: */24 #ifdef _HAVE_PETSC_25 MatFree(&(*pv)->pmatrix->matrix);26 #endif27 *pv=NULL;28 }29 }30 31 void xdelete_module(Vector** pv){32 33 if (pv && *pv){34 /*Actually, still get rid of internal Petsc vector. Quick fix until Matlab handles C++35 * correctly: */36 #ifdef _HAVE_PETSC_37 VecFree(&(*pv)->pvector->vector);38 #endif39 *pv=NULL;40 }41 } -
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/shared/Alloc/alloc_module.h
1 /* \file alloc.h2 */3 4 #ifndef _ALLOC_MODULE_H_5 #define _ALLOC_MODULE_H_6 class Matrix;7 class Vector;8 void xdelete_module(Matrix** pvptr);9 void xdelete_module(Vector** pvptr);10 11 #endif -
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/shared/shared.h
6 6 #define _SHARED_H_ 7 7 8 8 #include "Alloc/alloc.h" 9 #include "Alloc/alloc_module.h"10 9 #include "Alloc/xNewDelete.h" 11 10 #include "Bamg/shared.h" 12 11 #include "Elements/elements.h" -
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/Makefile.am
838 838 839 839 #}}} 840 840 #Modules sources{{{ 841 module_sources= ./shared/Alloc/alloc_module.h\ 842 ./shared/Alloc/alloc_module.cpp\ 843 ./shared/Threads/issm_threads.h\ 841 module_sources= ./shared/Threads/issm_threads.h\ 844 842 ./shared/Threads/LaunchThread.cpp\ 845 843 ./shared/Threads/PartitionRange.cpp\ 846 844 ./shared/Exp/exp.h\
Note:
See TracBrowser
for help on using the repository browser.