--- parser3/src/classes/table.C 2017/02/07 22:00:30 1.342 +++ parser3/src/classes/table.C 2017/12/05 22:59:57 1.346 @@ -17,12 +17,12 @@ #include "pa_vbool.h" #include "pa_array.h" -#if (!defined(NO_STRINGSTREAM) && !defined(FREEBSD4)) +#if (!defined(NO_STRINGSTREAM) && !defined(FREEBSD4) && !defined(PA_DEBUG_DISABLE_GC)) #include #define USE_STRINGSTREAM #endif -volatile const char * IDENT_TABLE_C="$Id: table.C,v 1.342 2017/02/07 22:00:30 moko Exp $"; +volatile const char * IDENT_TABLE_C="$Id: table.C,v 1.346 2017/12/05 22:59:57 moko Exp $"; // class @@ -465,7 +465,7 @@ static void _load(Request& r, MethodPara } #ifdef USE_STRINGSTREAM -#include "gc_allocator.h" +#include "../lib/gc/include/gc_allocator.h" typedef std::basic_stringstream, gc_allocator > pa_stringstream; typedef std::basic_string, gc_allocator > pa_string; @@ -1016,7 +1016,7 @@ static void _hash(Request& r, MethodPara } #ifndef DOXYGEN -struct Table_seq_item { +struct Table_seq_item : public PA_Allocated { ArrayString* row; union { const char *c_str; @@ -1048,7 +1048,7 @@ static void _sort(Request& r, MethodPara Table& old_table=GET_SELF(r, VTable).table(); Table& new_table=*new Table(old_table.columns()); - Table_seq_item* seq=new(PointerFreeGC) Table_seq_item[old_table.count()]; + Table_seq_item* seq=new Table_seq_item[old_table.count()]; int i; // calculate key values @@ -1299,7 +1299,7 @@ public: columns+=new String(str, String::L_TAINTED /* no length as 0x00 can be inside */); return false; } catch(...) { - error=SQL_Error("exception occured in Table_sql_event_handlers::add_column"); + error=SQL_Error("exception occurred in Table_sql_event_handlers::add_column"); return true; } } @@ -1309,7 +1309,7 @@ public: columns_count=columns.count(); return false; } catch(...) { - error=SQL_Error("exception occured in Table_sql_event_handlers::before_rows"); + error=SQL_Error("exception occurred in Table_sql_event_handlers::before_rows"); return true; } } @@ -1318,7 +1318,7 @@ public: *table+=row=new ArrayString(columns_count); return false; } catch(...) { - error=SQL_Error("exception occured in Table_sql_event_handlers::add_row"); + error=SQL_Error("exception occurred in Table_sql_event_handlers::add_row"); return true; } } @@ -1327,7 +1327,7 @@ public: *row+=str?new String(str, String::L_TAINTED /* no length as 0x00 can be inside */):&String::Empty; return false; } catch(...) { - error=SQL_Error("exception occured in Table_sql_event_handlers::add_row_cell"); + error=SQL_Error("exception occurred in Table_sql_event_handlers::add_row_cell"); return true; } } @@ -1351,7 +1351,7 @@ static void marshal_bind( // not static, used elsewhere int marshal_binds(HashStringValue& hash, SQL_Driver::Placeholder*& placeholders) { int hash_count=hash.count(); - placeholders=new SQL_Driver::Placeholder[hash_count]; + placeholders=new(PointerGC) SQL_Driver::Placeholder[hash_count]; SQL_Driver::Placeholder* ptr=placeholders; hash.for_each(marshal_bind, &ptr); return hash_count;