Imported Upstream version 1.1~20101101~SE~8e5f8df~SYSYNC~2a247a4 upstream/1.1_20101101_SE_8e5f8df_SYSYNC_2a247a4
authorPatrick Ohly <patrick.ohly@intel.com>
Fri, 28 Jun 2013 11:41:54 +0000 (11:41 +0000)
committerPatrick Ohly <patrick.ohly@intel.com>
Fri, 28 Jun 2013 11:41:54 +0000 (11:41 +0000)
ChangeLog
README
README.html
configure
configure.in
src/syncevo/FileConfigTree.cpp
src/syncevo/FileConfigTree.h
src/syncevo/SyncConfig.cpp
src/syncevo/SyncConfig.h
src/syncevo/VolatileConfigTree.h

index 43386b0..4972c10 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 # Generated by configure.  Do no edit.
 
+2010-11-01  Patrick Ohly  <patrick.ohly@intel.com>
+
+       * src/syncevo/FileConfigTree.cpp:
+       * src/syncevo/FileConfigTree.h:
+       * src/syncevo/SyncConfig.cpp:
+       * src/syncevo/SyncConfig.h:
+       * src/syncevo/VolatileConfigTree.h:
+
+       config handling: old-style configs not found anymore (BMC #9381)
+
 2010-10-26  Patrick Ohly  <patrick.ohly@intel.com>
 
        * NEWS:
diff --git a/README b/README
index eac11d8..63d025c 100644 (file)
--- a/README
+++ b/README
@@ -7,8 +7,8 @@ synchronize personal information management data
 ------------------------------------------------
 
 :Manual section: 1
-:Version: 1.1
-:Date: 2010-10-26
+:Version: 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4
+:Date: 2010-11-01
 
 SYNOPSIS
 ========
index ae6a94b..e53d455 100644 (file)
@@ -5,7 +5,7 @@
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 <meta name="generator" content="Docutils 0.6: http://docutils.sourceforge.net/" />
 <title>SyncEvolution</title>
-<meta name="date" content="2010-10-26" />
+<meta name="date" content="2010-11-01" />
 <style type="text/css">
 
 /*
@@ -315,9 +315,9 @@ ul.auto-toc {
 <tr class="field"><th class="docinfo-name">Manual section:</th><td class="field-body">1</td>
 </tr>
 <tr><th class="docinfo-name">Version:</th>
-<td>1.1</td></tr>
+<td>1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4</td></tr>
 <tr><th class="docinfo-name">Date:</th>
-<td>2010-10-26</td></tr>
+<td>2010-11-01</td></tr>
 </tbody>
 </table>
 <div class="section" id="synopsis">
index 8910bb8..fb3ca15 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for syncevolution 1.1.
+# Generated by GNU Autoconf 2.61 for syncevolution 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4.
 #
 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
 # 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
@@ -726,8 +726,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
 # Identity of this package.
 PACKAGE_NAME='syncevolution'
 PACKAGE_TARNAME='syncevolution'
-PACKAGE_VERSION='1.1'
-PACKAGE_STRING='syncevolution 1.1'
+PACKAGE_VERSION='1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4'
+PACKAGE_STRING='syncevolution 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4'
 PACKAGE_BUGREPORT=''
 
 # Factoring default headers for most tests.
@@ -1628,7 +1628,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures syncevolution 1.1 to adapt to many kinds of systems.
+\`configure' configures syncevolution 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1698,7 +1698,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of syncevolution 1.1:";;
+     short | recursive ) echo "Configuration of syncevolution 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4:";;
    esac
   cat <<\_ACEOF
 
@@ -2016,7 +2016,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-syncevolution configure 1.1
+syncevolution configure 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4
 generated by GNU Autoconf 2.61
 
 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -2030,7 +2030,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by syncevolution $as_me 1.1, which was
+It was created by syncevolution $as_me 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   $ $0 $@
@@ -2723,7 +2723,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='syncevolution'
- VERSION='1.1'
+ VERSION='1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -29497,7 +29497,7 @@ exec 6>&1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by syncevolution $as_me 1.1, which was
+This file was extended by syncevolution $as_me 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -29550,7 +29550,7 @@ Report bugs to <bug-autoconf@gnu.org>."
 _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF
 ac_cs_version="\\
-syncevolution config.status 1.1
+syncevolution config.status 1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4
 configured by $0, generated by GNU Autoconf 2.61,
   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
 
index 85e5411..87fe032 100644 (file)
@@ -8,7 +8,7 @@ dnl Invoke autogen.sh to produce a configure script.
 #
 # Starting with the 1.1 release cycle, the rpm-style
 # .99 pseudo-version number is used to mark a pre-release.
-AC_INIT([syncevolution], [1.1])
+AC_INIT([syncevolution], [1.1+20101101+SE+8e5f8df+SYSYNC+2a247a4])
 # STABLE_VERSION=1.0.1+
 AC_SUBST(STABLE_VERSION)
 
index 36097bd..486766c 100644 (file)
@@ -38,10 +38,10 @@ SE_BEGIN_CXX
 
 FileConfigTree::FileConfigTree(const string &root,
                                const string &peer,
-                               bool oldLayout) :
+                               SyncConfig::Layout layout) :
     m_root(root),
     m_peer(peer),
-    m_oldLayout(oldLayout),
+    m_layout(layout),
     m_readonly(false)
 {
 }
@@ -56,7 +56,7 @@ void FileConfigTree::flush()
     BOOST_FOREACH(const NodeCache_t::value_type &node, m_nodes) {
         node.second->flush();
     }
-    if (!m_oldLayout) {
+    if (m_layout == SyncConfig::SHARED_LAYOUT) {
         // ensure that "peers" directory exists for new-style configs,
         // not created by flushing nodes for pure context configs but
         // needed to detect new-syle configs
@@ -147,7 +147,7 @@ boost::shared_ptr<ConfigNode> FileConfigTree::open(const string &path,
     
     fullpath = normalizePath(m_root + "/" + path + "/");
     if (type == other) {
-        if (m_oldLayout) {
+        if (m_layout == SyncConfig::SYNC4J_LAYOUT) {
             fullpath += "/changes";
             if (!otherId.empty()) {
                 fullpath += "_";
@@ -164,7 +164,7 @@ boost::shared_ptr<ConfigNode> FileConfigTree::open(const string &path,
         }
     } else {
         filename = type == server ? ".server.ini" :
-            m_oldLayout ? "config.txt" :
+            m_layout == SyncConfig::SYNC4J_LAYOUT ? "config.txt" :
             type == hidden ? ".internal.ini" :
             "config.ini";
     }
index fc4e322..a475e82 100644 (file)
@@ -20,7 +20,8 @@
 #ifndef INCL_EVOLUTION_FILE_CONFIG_TREE
 # define INCL_EVOLUTION_FILE_CONFIG_TREE
 
-#include <ConfigTree.h>
+#include <syncevo/ConfigTree.h>
+#include <syncevo/SyncConfig.h>
 
 #include <string>
 #include <map>
@@ -41,11 +42,14 @@ class FileConfigTree : public ConfigTree {
      * @param root              absolute filesystem path for
      *                          .syncj4/evolution or .config/syncevolution
      * @param peer              the relative path to the peer configuration
-     * @param oldLayout         true: use pre-0.7 file names
+     * @param layout            determines file names to be used;
+     *                          HTTP_SERVER_LAYOUT and SHARED_LAYOUT are the same except
+     *                          that SHARED_LAYOUT creates the "peers" directory during
+     *                          flushing
      */
     FileConfigTree(const string &root,
                    const string &peer,
-                   bool oldLayout);
+                   SyncConfig::Layout layout);
 
     void setReadOnly(bool readonly) { m_readonly = readonly; }
     bool getReadOnly() const { return m_readonly; }
@@ -70,7 +74,7 @@ class FileConfigTree : public ConfigTree {
  private:
     const string m_root;
     const string m_peer;
-    const bool m_oldLayout;
+    SyncConfig::Layout m_layout;
     bool m_readonly;
 
     typedef map< string, boost::shared_ptr<ConfigNode> > NodeCache_t;
index 15b16e9..00b07c6 100644 (file)
@@ -203,7 +203,7 @@ SyncConfig::SyncConfig(const string &peer,
         }
         m_tree.reset(new FileConfigTree(root,
                                         m_peerPath.empty() ? m_contextPath : m_peerPath,
-                                        m_layout == SYNC4J_LAYOUT));
+                                        m_layout));
     }
 
     string path;
@@ -319,7 +319,7 @@ string SyncConfig::getRootPath() const
 void SyncConfig::addPeers(const string &root,
                           const std::string &configname,
                           SyncConfig::ConfigList &res) {
-    FileConfigTree tree(root, "", false);
+    FileConfigTree tree(root, "", SyncConfig::HTTP_SERVER_LAYOUT);
     list<string> servers = tree.getChildren("");
     BOOST_FOREACH(const string &server, servers) {
         // sanity check: only list server directories which actually
index e01a4b5..9f67299 100644 (file)
@@ -1364,7 +1364,6 @@ class SyncConfig {
     virtual const char*  getDevType() const;
     /**@}*/
 
-private:
     enum Layout {
         SYNC4J_LAYOUT,        /**< .syncj4/evolution/<server>, SyncEvolution <= 0.7.x */
         HTTP_SERVER_LAYOUT,   /**< .config/syncevolution/<server> with sources
@@ -1374,6 +1373,7 @@ private:
                                  SyncEvolution >= 1.0 */
     };
 
+private:
     /**
      * scans for peer configurations
      * @param root         absolute directory path
index 69ffe4d..3531ab3 100644 (file)
@@ -33,7 +33,7 @@ SE_BEGIN_CXX
 class VolatileConfigTree : public FileConfigTree {
  public:
  VolatileConfigTree() :
-    FileConfigTree("/dev/null", "", false)
+    FileConfigTree("/dev/null", "", SyncConfig::SHARED_LAYOUT)
         {}
 
     virtual void flush() {}