Project

Profile

Help

Revision 55b80284

Added by O'Neil Delpratt 5 months ago

Saxon/C added memory debugging and bug fixes

View differences:

src/main/c/Saxon.C.API/SaxonProcessor.h
8 8
#ifndef SAXON_PROCESSOR_H
9 9
#define SAXON_PROCESSOR_H
10 10

  
11

  
11 12
#if defined __linux__ || defined __APPLE__
12 13

  
13 14
#include <stdlib.h>
......
25 26
#define CVERSION "1.3.0"
26 27
#define CVERSION_API_NO 130
27 28

  
29

  
30

  
31

  
28 32
#include <string>
29 33
#include <iostream>
30 34
#include <sstream>
......
44 48
//#include "com_saxonica_functions_extfn_PhpCall.h"
45 49
//#include "com_saxonica_functions_extfn_PhpCall_PhpFunctionCall.h"
46 50

  
51
#if defined MEM_DEBUG
52

  
53

  
54
#include <algorithm>
55
#include <cstdlib>
56
#include <new>
57

  
58
static std::vector<void*> myAlloc;
59

  
60
void* newImpl(std::size_t sz,char const* file, int line);
61

  
62
void* operator new(std::size_t sz,char const* file, int line);
63

  
64
void* operator new [](std::size_t sz,char const* file, int line);
65

  
66
void operator delete(void* ptr) noexcept;
67

  
68
#endif
69

  
70

  
47 71
class XsltProcessor;
48 72

  
49 73
class Xslt30Processor;
......
276 300
    */
277 301
    XdmAtomicValue *makeAtomicValue(const char *type, const char *value);
278 302

  
279
#if CVERSION_API_NO >= 123
280

  
281 303
    /**
282 304
        * Make an XdmArray whose members are from string representation
283 305
        * @param input the input array of booleans
......
319 341
    XdmMap *makeMap(std::map<XdmAtomicValue *, XdmValue *> dataMap);
320 342

  
321 343

  
322
#endif
323

  
324 344
    /**
325 345
    * Get the string representation of the XdmValue.
326 346
    * @return char array
......
494 514

  
495 515

  
496 516

  
517

  
518

  
497 519
//	XPathEngine
498 520
//	XQueryEngine
499 521
//	SchemaManager
......
504 526
    std::string cwd; /*!< current working directory */
505 527
    jobject proc; /*!< Java Processor object */
506 528

  
529

  
530

  
531
    static void getInfo();
532

  
507 533
    /*static JavaVM *jvm;*/
508 534

  
509 535
protected:
......
545 571
    static const char *checkException();
546 572
};
547 573

  
574

  
548 575
//===============================================================================================
549 576

  
577

  
578

  
550 579
#endif /* SAXON_PROCESSOR_H */

Also available in: Unified diff