OSDN Git Service

akregator: update Metakit to 2.4.9.8
authorIvailo Monev <xakepa10@gmail.com>
Sat, 20 Jun 2015 14:29:07 +0000 (17:29 +0300)
committerIvailo Monev <xakepa10@gmail.com>
Sat, 20 Jun 2015 14:33:01 +0000 (17:33 +0300)
50 files changed:
akregator/plugins/mk4storage/CMakeLists.txt
akregator/plugins/mk4storage/metakit/CHANGES
akregator/plugins/mk4storage/metakit/README
akregator/plugins/mk4storage/metakit/include/mk4.h
akregator/plugins/mk4storage/metakit/include/mk4.inl
akregator/plugins/mk4storage/metakit/include/mk4dll.h
akregator/plugins/mk4storage/metakit/include/mk4io.h
akregator/plugins/mk4storage/metakit/include/mk4str.h
akregator/plugins/mk4storage/metakit/include/mk4str.inl
akregator/plugins/mk4storage/metakit/license.terms
akregator/plugins/mk4storage/metakit/src/borc.h
akregator/plugins/mk4storage/metakit/src/column.cpp
akregator/plugins/mk4storage/metakit/src/column.h
akregator/plugins/mk4storage/metakit/src/column.inl
akregator/plugins/mk4storage/metakit/src/custom.cpp
akregator/plugins/mk4storage/metakit/src/custom.h
akregator/plugins/mk4storage/metakit/src/derived.cpp
akregator/plugins/mk4storage/metakit/src/derived.h
akregator/plugins/mk4storage/metakit/src/doxy.h
akregator/plugins/mk4storage/metakit/src/field.cpp
akregator/plugins/mk4storage/metakit/src/field.h
akregator/plugins/mk4storage/metakit/src/field.inl
akregator/plugins/mk4storage/metakit/src/fileio.cpp
akregator/plugins/mk4storage/metakit/src/format.cpp
akregator/plugins/mk4storage/metakit/src/format.h
akregator/plugins/mk4storage/metakit/src/gnuc.h
akregator/plugins/mk4storage/metakit/src/handler.cpp
akregator/plugins/mk4storage/metakit/src/handler.h
akregator/plugins/mk4storage/metakit/src/handler.inl
akregator/plugins/mk4storage/metakit/src/header.h
akregator/plugins/mk4storage/metakit/src/mfc.h
akregator/plugins/mk4storage/metakit/src/msvc.h
akregator/plugins/mk4storage/metakit/src/mwcw.h
akregator/plugins/mk4storage/metakit/src/persist.cpp
akregator/plugins/mk4storage/metakit/src/persist.h
akregator/plugins/mk4storage/metakit/src/remap.cpp
akregator/plugins/mk4storage/metakit/src/remap.h
akregator/plugins/mk4storage/metakit/src/std.cpp
akregator/plugins/mk4storage/metakit/src/std.h
akregator/plugins/mk4storage/metakit/src/store.cpp
akregator/plugins/mk4storage/metakit/src/store.h
akregator/plugins/mk4storage/metakit/src/store.inl
akregator/plugins/mk4storage/metakit/src/string.cpp
akregator/plugins/mk4storage/metakit/src/table.cpp
akregator/plugins/mk4storage/metakit/src/univ.cpp
akregator/plugins/mk4storage/metakit/src/univ.h
akregator/plugins/mk4storage/metakit/src/univ.inl
akregator/plugins/mk4storage/metakit/src/view.cpp
akregator/plugins/mk4storage/metakit/src/viewx.cpp
akregator/plugins/mk4storage/metakit/src/win.h

index 42b00a5..d37efa3 100644 (file)
@@ -1,3 +1,29 @@
+include(CheckIncludeFiles)
+include(CheckFunctionExists)
+include(CheckTypeSize)
+include(CTest)
+
+check_include_files(dlfcn.h HAVE_DLFCN_H)
+check_include_files(inttypes.h HAVE_INTTYPES_H)
+check_include_files(memory.h HAVE_MEMORY_H)
+check_include_files(stdint.h HAVE_STDINT_H)
+check_include_files(stdlib.h HAVE_STDLIB_H)
+check_include_files(strings.h HAVE_STRINGS_H)
+check_include_files(string.h HAVE_STRING_H)
+check_include_files(sys/stat.h HAVE_SYS_STAT_H)
+check_include_files(sys/types.h HAVE_SYS_TYPES_H)
+check_include_files(unistd.h HAVE_UNISTD_H)
+
+check_function_exists(bcopy HAVE_BCOPY)
+check_function_exists(memmove HAVE_MEMMOVE)
+check_function_exists(mmap HAVE_MMAP)
+
+set(CMAKE_EXTRA_INCLUDE_FILES)
+check_type_size(long SIZEOF_LONG)
+check_type_size("long long" LONG_LONG)
+
+configure_file(config-metakit.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-metakit.h)
+
 include_directories(
   ${CMAKE_CURRENT_SOURCE_DIR}
   ${CMAKE_CURRENT_BINARY_DIR}
index ec725b3..3b919e6 100644 (file)
@@ -1,3 +1,87 @@
+2015-06-18    ############################################    MK 2.4.9.8
+
+    Consolidate all the changes since the move to GitHub.
+
+2011-08-18    Move code to public repository on GitHub
+
+    The Subversion repository at svn://svn.equi4.com/metakit is now
+    obsolete. GitHub has the new official repository for Metakit.
+
+2009-02-10    Create Python install dir if not yet present
+
+    As with C++ and Tcl, the installation directory is created if
+    it did not exist (patch provided by A. Sampson).
+
+2007-06-25    Various Tcl tweaks (recovered from SVN log)
+
+    Cleanup/overhaul, adding CONST86, stubs, and Tcl_GetErrorLine
+    compatibility to allow compiling Mk4tcl for Tcl 8.6*.
+
+2007-06-24    Tcl TEA3 overhaul
+
+    Replace configure.in/Makefile.in with new versions, adapted from
+    Tcl's sampleextension.  Now generates config.h and pkgIndex.tcl
+    from corresponding *.in files.
+    
+    Comnvert all tcl/test/ entries to new ones in tcl/tests/ to use
+    the standard tcltest framework.  Just 40 tests in all so far.
+    
+    Update to tcl.m4 3.6, with a patch to fix "make test" on macosx.
+
+2007-06-24    Cleanup obsolete code
+
+    Remove Lua binding in lua/ - it was never actually completed.
+    Remove win/{catfish,kitviewer,msevc3,msvc152} - now unsupported.
+    Remove mac/, pre-macosx builds are no longer supported.
+    Removed the MKSQL logic and tcl/mksql.tcl, since it is not used.
+
+2007-06-24    Patch for cygwin
+
+    There's a submitted patch (F152) which tries to fix a problem
+    when compilng MK on cygwin with CXXFLAGS=-mno-cygwin, but it may
+    not be the best way to fix things.  Instead, this change adds the
+    $(LDFLAGS) parameter in a few places in the Makefile.  It was not
+    used before, and $(SHLIB_FLAGS) still isn't being used - weird.
+
+2007-06-18    Fix threading problems in Mk4tcl
+
+    A change is needed to make the thread fix work with mk::loop,
+    because the _ws pointer could be null in FreeCursorInternalRep.
+    Fixed by no longer clearing _ws and changing a test for that case.
+
+2007-06-16    ############################################    MK 2.4.9.7
+
+    If you're using Tcl in threaded mode, please upgrade - see below.
+
+2007-06-16    Fix threading problems in Mk4tcl
+
+    The Mk4tcl binding had two serious bugs, causing potential crashes
+    and database corruption when used in multi-threaded mode:
+    
+    1) The Makefile did not set -DTCL_THREADS when configured with
+       the "--enable-threads" flag, only -Dq4_MULTI, which is the C++
+       level threading support of Metakit.  So all builds were still
+       running the Mk4tcl wrapper in unprotected mode (!).
+       
+    2) Tcl's type conversion callbacks did not contain mutex calls to
+       prevent calls from Tcl into Mk4tcl other than mk::* commands.
+       This happens during "Tcl_ObjType mkCursorType" type conversions.
+       
+    Added the proper -DTCL_THREADS flag to Makefile.in, and extra code
+    to implement recursive mutex protection on top of Tcl's primitives.
+    
+    This problem does not affect the C++ core (which has been in use in
+    threaded mode for some time, on many platforms including Windows),
+    nor the Mk4py binding for Python which uses a global interp lock.
+
+2007-02-12    Continue unmapped, also in debug mode
+
+    In the WIN32 version of ResetFileMapping, there were two assertions
+    which made the code fail in debug builds, even though both cases are
+    properly handled with if's.  Dropped the asserts, so that the logic
+    is the same as in release builds: when memory mapping fails, simply
+    continue without memory mapping and fall back to buffering all data.
+
 2006-11-15    ############################################    MK 2.4.9.6
 
     Please upgrade, this consolidates a year with various fixes.
index 65f77fa..2f741f7 100644 (file)
@@ -1,4 +1,4 @@
-The Metakit Library 2.4.9.6                                           Nov 2006
+The Metakit Library 2.4.9.8                                           Jun 2015
 ==============================================================================
 
 
@@ -25,9 +25,9 @@ PYTHON - The binding for Python is called "Mk4py".  It uses SCXX by Gordon
 TCL/TK - The MK extension for Tcl is called "Mk4tcl".  It is being used in a
     number of commercial projects.  The source is in directory "tcl/".
 
-LICENSE AND SUPPORT - Metakit is now distributed as open source software (the
-    X/MIT-style license is at the end of this document).  Commercial support
-    is available through an Enterprise License, see the URL mentioned below.
+LICENSE AND SUPPORT - Metakit is distributed as open source software (see the
+    X/MIT-style license at the end of this document).  Commercial support is
+    available through an Enterprise License, see the URL mentioned below.
 
 DOCUMENTATION - All documentation uses HTML.  The main page is "Metakit.html",
     which leads to the rest of the documentation in the "doc/" directory.
@@ -37,8 +37,8 @@ WEBSITE URLS - The main pages on the world wide web, for news and downloads:
     Homepage:       http://www.equi4.com/metakit.html
     Python news:    http://www.equi4.com/metakit/python.html
     Tcl/Tk news:    http://www.equi4.com/metakit/tcl.html
-    License info:   http://www.equi4.com/mklicense.html
-    Contact info:   http://www.equi4.com/contact.html
+    License info:   http://www.equi4.com/metakit/license.html
+    Contact info:   http://www.equi4.com/about/contact.html
 
 ACKNOWLEDGEMENTS - Thanks to everyone who has helped shape and extend Metakit,
     including Kyrill Denisenko, Mark Roseman, Gordon McMillan, Matt Newman,
@@ -91,26 +91,24 @@ PYTHON - Nov 2006
     the flags don't seem to create proper executables.  That's ok though, the
     .o files are fat, which is all setup.py needs.
 
-TCL - Nov 2006
+TCL - Jun 2007
 
-    The unix/configure works better for Tcl than for Python, due to the stubs
-    interface.  In many cases, adding --with-tcl or --with-tcl=<dir-of-tcl.h>
-    will produce a Mk4tcl.so (or a Mk4tcl.dylib on Mac OS X).
-    
-    Alternately, you could use the TEA3-based tcl/configure script.  It needs
-    a few preliminary steps to get a proper config.h file in the right spot:
-        cd builds
-        sh ../unix/configure
-        cd ../tcl
-        ln -s ../builds/config.h
-        sh configure
+    The Tcl build has been converted to use the TEA3-based configure script
+    in the tcl/ directory.  The way to build Mk4tcl is now as follows:
+
+        mkdir tbuild      # can be anywhere, really...
+        cd tbuild
+        CC=g++ sh ../tcl/configure
         make
-    There are still some issues, the above generates a lot of warning errors.    
-    Note that this does not depend on .o files in ../builds, just config.h
+        make test
+        make install
+
+    This build configuration has not yet been tested with non-gcc compilers.
+    There are no dependencies on the C++ build process, nor the builds/ dir.
     
-    Note: for Windows CE, the tcl.configure script has been successfully used
-    using EVC3.  One trick is that in tcl/configure.in, "TEA_ADD_CFLAGS([])"
-    has to be changed to "TEA_ADD_CFLAGS([-Dq4_WINCE])".
+    Note: for Windows CE, an older version of the tcl.configure script was
+    successfully used with MS EVC3.  One trick is that in tcl/configure.in,
+    "TEA_ADD_CFLAGS([])" has to be changed to "TEA_ADD_CFLAGS([-Dq4_WINCE])".
     
 UNIX (ALSO MAC OS X)
 
@@ -176,19 +174,11 @@ WINDOWS
     efficiency on x86 hardware: "-O2 -m486 -malign-loops=2 -malign-jumps=2".
     I have not yet tried this myself, but am passing on the tip.
 
-MACINTOSH CLASSIC
-
-    The Mac version requires Metrowerks CodeWarrior 6.  See the info above
-    in the Windows section (MWCW is multi-platform).  The projects are all
-    located in the "mac/" folder, which is also where MWCW will place its own
-    "... Data" folders with intermediate results.  As with all other setups,
-    final results are made to end up in the "builds/" directory.
-
 
 LICENSE AND COPYRIGHT STATEMENT
 ===============================
 
-Copyright (c) 1996-2006 Jean-Claude Wippler
+Copyright (c) 1996-2007 Jean-Claude Wippler
 
 Permission is hereby granted, free of charge, to any person obtaining a
 copy of this software and associated documentation files (the "Software"),
@@ -210,4 +200,4 @@ DEALINGS IN THE SOFTWARE.
 
 
 ==============================================================================
--- Jean-Claude Wippler <jcw@equi4.com>
+-- Jean-Claude Wippler <jc@wippler.nl>
index 25af2a5..d7d97c0 100644 (file)
@@ -1,5 +1,5 @@
 // mk4.h --
-// $Id: mk4.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -9,6 +9,8 @@
 #ifndef __MK4_H__
 #define __MK4_H__
 
+#include <stdint.h>
+
 //---------------------------------------------------------------------------
 //
 //  TITLE
@@ -43,7 +45,7 @@
 //---------------------------------------------------------------------------
 
 /// Current release = 100 * major + 10 * minor + maintenance
-#define d4_MetakitLibraryVersion 249    // 2.4.9.6 release, Nov 15, 2006
+#define d4_MetakitLibraryVersion 249    // 2.4.9.8 release, Jun 18, 2015
 #define d4_MetaKitLibraryVersion d4_MetakitLibraryVersion // compat, yuck
 
 //---------------------------------------------------------------------------
@@ -197,28 +199,9 @@ defined(__x86_64__) || defined(__s390x__) || defined(__alpha) ||  \
 #define d4_inline
 #endif 
 
-typedef unsigned char t4_byte; // create typedefs for t4_byte, etc.
-
-#if q4_LONG64
-typedef int t4_i32; // if longs are 64b, then int must be 32b
-#else 
-typedef long t4_i32; // if longs aren't 64b, then they are 32b
-#endif 
-
-#if q4_LONG64           // choose a way to represent 64b integers
-typedef long t4_i64;
-#elif defined (LONG_LONG)
-typedef LONG_LONG t4_i64;
-#elif HAVE_LONG_LONG
-typedef long long t4_i64;
-#else 
-struct t4_i64 {
-    long l1;
-    long l2;
-};
-bool operator == (const t4_i64 a_, const t4_i64 b_);
-bool operator < (const t4_i64 a_, const t4_i64 b_);
-#endif 
+typedef uint8_t t4_byte; // create typedefs for t4_byte, etc.
+typedef int32_t t4_i32; // if longs are 64b, then int must be 32b
+typedef int64_t t4_i64;
 
 //---------------------------------------------------------------------------
 
index 4bf60af..a92f924 100644 (file)
@@ -1,5 +1,5 @@
 // mk4.inl --
-// $Id: mk4.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
@@ -284,7 +284,7 @@ d4_inline bool operator!= (c4_Cursor a_, c4_Cursor b_)
 d4_inline bool operator< (c4_Cursor a_, c4_Cursor b_)
 {
   return a_._seq < b_._seq ||
-         a_._seq == b_._seq && a_._index < b_._index;
+         (a_._seq == b_._seq && a_._index < b_._index);
 }
 
 d4_inline bool operator> (c4_Cursor a_, c4_Cursor b_)
index 8992f85..444649f 100644 (file)
@@ -1,5 +1,5 @@
 // mk4dll.h --
-// $Id: mk4dll.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 //
 //  Import declarations for DLLs
index 5cd8324..4e47f1b 100644 (file)
@@ -1,5 +1,5 @@
 // mk4io.h --
-// $Id: mk4io.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 892fdb8..e334e6a 100644 (file)
@@ -1,5 +1,5 @@
 // mk4str.h --
-// $Id: mk4str.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index 1fc1bad..fde153d 100644 (file)
@@ -1,5 +1,5 @@
 // mk4str.inl --
-// $Id: mk4str.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index b64dbe9..48bfb77 100644 (file)
@@ -1,4 +1,4 @@
-Copyright (c) 1996-2004 Jean-Claude Wippler
+Copyright (c) 1996-2015 Jean-Claude Wippler
 
 Permission is hereby granted, free of charge, to any person obtaining a
 copy of this software and associated documentation files (the "Software"),
index 1a92f10..69eefb9 100644 (file)
@@ -1,5 +1,5 @@
 // borc.h --
-// $Id: borc.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index fb05f34..5379e75 100644 (file)
@@ -1,5 +1,5 @@
 // column.cpp --
-// $Id: column.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
@@ -99,9 +99,10 @@ bool c4_Column::IsMapped()const {
 
 bool c4_Column::UsesMap(const t4_byte *ptr_)const {
   // the most common falsifying case is checked first
-  return _persist != 0 && ptr_ >= Strategy()._mapStart && Strategy()._dataSize
-    != 0 &&  // added  2003-05-08, thx V DeMarco
-  ptr_ < Strategy()._mapStart + Strategy()._dataSize;
+  return _persist != 0 &&
+    ptr_ >= Strategy()._mapStart &&
+    Strategy()._dataSize != 0 &&
+    ptr_ < Strategy()._mapStart + Strategy()._dataSize;
 }
 
 bool c4_Column::RequiresMap()const {
@@ -417,13 +418,15 @@ void c4_Column::MoveGapTo(t4_i32 pos_) {
   // move the gap up, ie. some bytes down
     MoveGapUp(pos_);
   else if (_gap > pos_)
-  // move the gap down, ie. some bytes up
-  if (_gap - pos_ > _size - _gap + fSegRest(pos_)) {
-    RemoveGap(); // it's faster to get rid of the gap instead
-    _gap = pos_;
-  } else
-  // normal case, move some bytes up
-    MoveGapDown(pos_);
+  {
+    // move the gap down, ie. some bytes up
+    if (_gap - pos_ > _size - _gap + fSegRest(pos_)) {
+      RemoveGap(); // it's faster to get rid of the gap instead
+      _gap = pos_;
+    } else
+    // normal case, move some bytes up
+      MoveGapDown(pos_);
+  }
 
   d4_assert(_gap == pos_);
 
@@ -1174,7 +1177,7 @@ void c4_ColOfInts::SetAccessWidth(int bits_) {
 
   _currWidth = (1 << l2bp1) >> 1;
 
-  if (l2bp1 > 4 && (_mustFlip || Persist() != 0 && Strategy()._bytesFlipped))
+  if (l2bp1 > 4 && (_mustFlip || (Persist() != 0 && Strategy()._bytesFlipped)))
     l2bp1 += 3;
   // switch to the trailing entries for byte flipping
 
index ac7967a..4f33d4f 100644 (file)
@@ -1,5 +1,5 @@
 // column.h --
-// $Id: column.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index fe86007..ce9efea 100644 (file)
@@ -1,5 +1,5 @@
 // column.inl --
-// $Id: column.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 2c52861..6f58a2d 100644 (file)
@@ -1,5 +1,5 @@
 // custom.cpp --
-// $Id: custom.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -762,19 +762,21 @@ bool c4_JoinPropViewer::GetItem(int row_, int col_, c4_Bytes &buf_) {
   int r = _base.GetAt(row_);
 
   if (col_ >= _subPos)
-  if (col_ >= _subPos + _subWidth) {
-    col_ -= _subWidth - 1;
-  } else {
-    v = _sub(_parent[r]);
-    r = _offset.GetAt(row_);
-    if (r < 0)
-      return false;
-    // if this is a null row in an outer join
-
-    col_ = v.FindProperty(_template.NthProperty(col_).GetId());
-    if (col_ < 0)
-      return false;
-    // if subview doesn't have all properties
+  {
+    if (col_ >= _subPos + _subWidth) {
+      col_ -= _subWidth - 1;
+    } else {
+      v = _sub(_parent[r]);
+      r = _offset.GetAt(row_);
+      if (r < 0)
+        return false;
+      // if this is a null row in an outer join
+
+      col_ = v.FindProperty(_template.NthProperty(col_).GetId());
+      if (col_ < 0)
+        return false;
+      // if subview doesn't have all properties
+    }
   }
 
   return v.GetItem(r, col_, buf_);
index 3e06c87..1a8593d 100644 (file)
@@ -1,5 +1,5 @@
 // custom.h --
-// $Id: custom.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index b5e7ca7..ff811ff 100644 (file)
@@ -1,5 +1,5 @@
 // derived.cpp --
-// $Id: derived.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -292,13 +292,15 @@ c4_Notifier *c4_FilterSeq::PreChange(c4_Notifier &nf_) {
 
       bool includeRow = r >= 0;
       if (!pass)
-      if (nf_._type == c4_Notifier::kSetAt) {
-        d4_assert(nf_._cursor != 0);
-        includeRow = Match(nf_._cursor->_index, *nf_._cursor->_seq);
+      {
+        if (nf_._type == c4_Notifier::kSetAt) {
+          d4_assert(nf_._cursor != 0);
+          includeRow = Match(nf_._cursor->_index, *nf_._cursor->_seq);
+        }
+         else
+        // set just one property, and it's not in a row yet
+          includeRow = MatchOne(nf_._propId,  *nf_._bytes);
       }
-       else
-      // set just one property, and it's not in a row yet
-        includeRow = MatchOne(nf_._propId,  *nf_._bytes);
 
       if (r >= 0 && !includeRow)
         chg->StartRemoveAt(r, 1);
@@ -360,13 +362,15 @@ void c4_FilterSeq::PostChange(c4_Notifier &nf_) {
 
       bool includeRow = r >= 0;
       if (!pass)
-      if (nf_._type == c4_Notifier::kSetAt) {
-        d4_assert(nf_._cursor != 0);
-        includeRow = Match(nf_._cursor->_index, *nf_._cursor->_seq);
+      {
+        if (nf_._type == c4_Notifier::kSetAt) {
+          d4_assert(nf_._cursor != 0);
+          includeRow = Match(nf_._cursor->_index, *nf_._cursor->_seq);
+        }
+         else
+        // set just one property, and it's not in a row yet
+          includeRow = MatchOne(nf_._propId,  *nf_._bytes);
       }
-       else
-      // set just one property, and it's not in a row yet
-        includeRow = MatchOne(nf_._propId,  *nf_._bytes);
 
       if (r >= 0 && !includeRow)
         _rowMap.RemoveAt(r);
index d5ed133..b599882 100644 (file)
@@ -1,5 +1,5 @@
 // derived.h --
-// $Id: derived.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 60a7fca..3e20319 100644 (file)
@@ -1,5 +1,5 @@
 // doxy.h --
-// $Id: doxy.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @mainpage Metakit API Reference
index 025ef96..fdec1a4 100644 (file)
@@ -1,5 +1,5 @@
 // field.cpp --
-// $Id: field.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 63f802e..b70229a 100644 (file)
@@ -1,5 +1,5 @@
 // field.h --
-// $Id: field.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index 2792211..2bf183b 100644 (file)
@@ -1,5 +1,5 @@
 // field.inl --
-// $Id: field.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index fad2db8..87ea342 100644 (file)
@@ -1,5 +1,5 @@
 // fileio.cpp --
-// $Id: fileio.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -261,11 +261,9 @@ void c4_FileStrategy::ResetFileMapping() {
       FlushFileBuffers((HANDLE)_get_osfhandle(_fileno(_file)));
       HANDLE h = ::CreateFileMapping((HANDLE)_get_osfhandle(_fileno(_file)), 0,
         PAGE_READONLY, 0, len, 0);
-      d4_assert(h); // check for errors, but can continue without mapping
 
       if (h) {
         _mapStart = (t4_byte*)::MapViewOfFile(h, FILE_MAP_READ, 0, 0, len);
-        d4_assert(_mapStart != 0);
 
         if (_mapStart != 0) {
           _mapStart += _baseOffset;
index 2181520..a1a0d9b 100644 (file)
@@ -1,5 +1,5 @@
 // format.cpp --
-// $Id: format.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
@@ -331,7 +331,7 @@ d4_inline bool c4_FormatB::ShouldBeMemo(int length_)const {
   // as is, and so do memos which have not been modified
 
   int rows = _memos.GetSize() + 1; // avoids divide by zero
-  return length_ > 10000 || length_ > 100 && length_ > 1000000 / rows;
+  return length_ > 10000 || (length_ > 100 && length_ > 1000000 / rows);
 }
 
 int c4_FormatB::ItemLenOffCol(int index_, t4_i32 &off_, c4_Column * &col_) {
@@ -356,13 +356,15 @@ c4_Column *c4_FormatB::GetNthMemoCol(int index_, bool alloc_) {
     _memos.SetAt(index_, col);
 
     if (n > 0)
-    if (_data.IsDirty()) {
-      c4_Bytes temp;
-      _data.FetchBytes(start, n, temp, true);
-      col->SetBuffer(n);
-      col->StoreBytes(0, temp);
-    } else
-      col->SetLocation(_data.Position() + start, n);
+    {
+      if (_data.IsDirty()) {
+        c4_Bytes temp;
+        _data.FetchBytes(start, n, temp, true);
+        col->SetBuffer(n);
+        col->StoreBytes(0, temp);
+      } else
+        col->SetLocation(_data.Position() + start, n);
+    }
   }
 
   return col;
@@ -809,8 +811,8 @@ void c4_FormatB::Commit(c4_SaveContext &ar_) {
   // both _sizeCol and _memoCol will be clean again when it has
   // but be careful because dirty flag is only useful if size is nonzero
   if (_recalc && !ar_.Serializing())
-    _recalc = _sizeCol.ColSize() > 0 && _sizeCol.IsDirty() || _memoCol.ColSize()
-      > 0 && _memoCol.IsDirty();
+    _recalc = (_sizeCol.ColSize() > 0 && _sizeCol.IsDirty())
+           || (_memoCol.ColSize() > 0 && _memoCol.IsDirty());
 }
 
 /////////////////////////////////////////////////////////////////////////////
index 587343e..52db9cd 100644 (file)
@@ -1,5 +1,5 @@
 // format.h --
-// $Id: format.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index deda791..06d9717 100644 (file)
@@ -1,5 +1,5 @@
 // gnuc.h --
-// $Id: gnuc.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index f275fc7..88ee5e4 100644 (file)
@@ -1,5 +1,5 @@
 // handler.cpp --
-// $Id: handler.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index c52ff6b..5a655fe 100644 (file)
@@ -1,5 +1,5 @@
 // handler.h --
-// $Id: handler.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 38a873f..482148a 100644 (file)
@@ -1,5 +1,5 @@
 // handler.inl --
-// $Id: handler.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index b1a5ad0..8c9c3f1 100644 (file)
@@ -1,5 +1,5 @@
 // header.h --
-// $Id: header.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
@@ -11,8 +11,8 @@
 
 /////////////////////////////////////////////////////////////////////////////
 
-#include <config-akregator.h>
-
+#include <config-metakit.h>
+#include <stdint.h>
 /////////////////////////////////////////////////////////////////////////////
 // A number of preprocessor options are used in the source code
 //
@@ -137,13 +137,8 @@ defined(_AIX) || defined(__hpux)
 extern void f4_memmove(void *d, const void *s, int n);
 #endif 
 
-typedef unsigned char t4_byte; // create typedefs for t4_byte, etc.
-
-#if SIZEOF_LONG == 8
-typedef int t4_i32; // longs are 64b, so int must be 32b
-#else 
-typedef long t4_i32; // longs aren't 64b, so they are 32b
-#endif 
+typedef uint8_t t4_byte; // create typedefs for t4_byte, etc.
+typedef int32_t t4_i32; // longs are 64b, so int must be 32b
 
 /////////////////////////////////////////////////////////////////////////////
 // Include header files which contain additional os/cpu/ide/fw specifics
index 112cc9f..9686541 100644 (file)
@@ -1,5 +1,5 @@
 // mfc.h --
-// $Id: mfc.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index 1a654cb..45452f1 100644 (file)
@@ -1,5 +1,5 @@
 // msvc.h --
-// $Id: msvc.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 39349bb..69ca4f9 100644 (file)
@@ -1,5 +1,5 @@
 // mwcw.h --
-// $Id: mwcw.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index 42a6c3e..4aa4673 100644 (file)
@@ -1,5 +1,5 @@
 // persist.cpp --
-// $Id: persist.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 1c5920b..4fd5132 100644 (file)
@@ -1,5 +1,5 @@
 // persist.h --
-// $Id: persist.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index fd4494b..e533499 100644 (file)
@@ -1,5 +1,5 @@
 // remap.cpp --
-// $Id: remap.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
@@ -238,7 +238,7 @@ int c4_HashViewer::LookDict(t4_i32 hash_, c4_Cursor cursor_)const {
   /* We use ~hash_ instead of hash_, as degenerate hash functions, such
   as for ints <sigh>, can have lots of leading zeros. It's not
   really a performance risk, but better safe than sorry. */
-  if (IsUnused(i) || Hash(i) == hash_ && KeySame(Row(i), cursor_))
+  if (IsUnused(i) || (Hash(i) == hash_ && KeySame(Row(i), cursor_)))
     return i;
 
   int freeslot = IsDummy(i) ? i :  - 1;
@@ -1054,10 +1054,12 @@ bool c4_IndexedViewer::RemoveRows(int pos_, int count_) {
   while (--n >= 0) {
     int v = _mapProp(_map[n]);
     if (v >= pos_)
+    {
       if (v < pos_ + count_)
         _map.RemoveAt(n);
       else
         _mapProp(_map[n]) = v - count_;
+    }
   }
 
   return true;
index b2d24bb..a81ac40 100644 (file)
@@ -1,5 +1,5 @@
 // remap.h --
-// $Id: remap.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index c2965bb..36d8928 100644 (file)
@@ -1,5 +1,5 @@
 // std.cpp --
-// $Id: std.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index a5fb03a..4da705b 100644 (file)
@@ -1,5 +1,5 @@
 // std.h --
-// $Id: std.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index 8a1a3ac..a3f6724 100644 (file)
@@ -1,5 +1,5 @@
 // store.cpp --
-// $Id: store.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index cde8583..8d105f4 100644 (file)
@@ -1,5 +1,5 @@
 // store.h --
-// $Id: store.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index f19aeb6..1dd345d 100644 (file)
@@ -1,5 +1,5 @@
 // store.inl --
-// $Id: store.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index ba3ee33..a661240 100644 (file)
@@ -1,5 +1,5 @@
 // string.cpp --
-// $Id: string.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -230,8 +230,8 @@ c4_String c4_String::Right(int nCount)const {
 }
 
 bool operator == (const c4_String &a, const c4_String &b) {
-  return a._value == b._value || a.GetLength() == b.GetLength() && memcmp
-    (a.Data(), b.Data(), a.GetLength()) == 0;
+  return a._value == b._value || (a.GetLength() == b.GetLength() && memcmp
+    (a.Data(), b.Data(), a.GetLength()) == 0);
 }
 
 int c4_String::Compare(const char *str)const {
index d689cd0..c1251d4 100644 (file)
@@ -1,5 +1,5 @@
 // table.cpp --
-// $Id: table.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 9dc12b7..f2412de 100644 (file)
@@ -1,5 +1,5 @@
 // univ.cpp --
-// $Id: univ.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index c9561cf..6b9be40 100644 (file)
@@ -1,5 +1,5 @@
 // univ.h --
-// $Id: univ.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 7094744..c78b2c3 100644 (file)
@@ -1,5 +1,5 @@
 // univ.inl --
-// $Id: univ.inl 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
index c17eddf..4086d5e 100644 (file)
@@ -1,5 +1,5 @@
 // view.cpp --
-// $Id: view.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file
index 596a5bf..b47cf57 100644 (file)
@@ -1,5 +1,5 @@
 // viewx.cpp --
-// $Id: viewx.cpp 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, see http://www.equi4.com/metakit.html
 
 /** @file
@@ -694,7 +694,7 @@ t4_i32 c4_Strategy::EndOfData(t4_i32 end_) {
       offset = (offset << 8) + mark[j];
 
     const bool isSkipTail = ((mark[0] & 0xF0) == 0x90 /* 2006-11-11 */ ||
-                             mark[0] == 0x80 && count == 0) && offset > 0;
+                             (mark[0] == 0x80 && count == 0)) && offset > 0;
     const bool isCommitTail = mark[0] == 0x80 && count > 0 && offset > 0;
     const bool isHeader = (mark[0] == 'J' || mark[0] == 'L') && (mark[0] ^
       mark[1]) == ('J' ^ 'L') && mark[2] == 0x1A && (mark[3] & 0x40) == 0;
index 4b5680d..209c594 100644 (file)
@@ -1,5 +1,5 @@
 // win.h --
-// $Id: win.h 1258 2007-03-09 16:48:38Z jcw $
+// $Id$
 // This is part of Metakit, the homepage is http://www.equi4.com/metakit.html
 
 /** @file