OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Ralf S. Engelschall
  Root:   /v/openpkg/cvs                   Email:  [EMAIL PROTECTED]
  Module: openpkg-src                      Date:   17-Apr-2008 07:59:42
  Branch: HEAD                             Handle: 2008041706594200

  Modified files:
    openpkg-src/monotone    monotone.patch monotone.spec

  Log:
    one more upstream vendor fix

  Summary:
    Revision    Changes     Path
    1.18        +57 -0      openpkg-src/monotone/monotone.patch
    1.35        +1  -1      openpkg-src/monotone/monotone.spec
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/monotone/monotone.patch
  ============================================================================
  $ cvs diff -u -r1.17 -r1.18 monotone.patch
  --- openpkg-src/monotone/monotone.patch       14 Apr 2008 19:25:42 -0000      
1.17
  +++ openpkg-src/monotone/monotone.patch       17 Apr 2008 05:59:42 -0000      
1.18
  @@ -107,3 +107,60 @@
      void sign_data(Botan::RSA_PublicKey const & key,
                     std::string const & data,
                     std::string & out);
  +
  +-----------------------------------------------------------------------------
  +
  +Upstream fix:
  +
  +If the options --db or --keydir were previously specified for a 
  +command which was executed inside a workspace and one or both
  +option arguments were invalid (f.e. invalid paths), they were 
  +still written to _MTN/options of the particular workspace.
  +This lead to errors on any subsequent command which used these 
  +options. This bug is fixed in so far that basic file type
  +checks are applied on both options, so its no longer possible
  +to set non-existing paths accidently or use a path to a directory
  +as option argument for --db.
  +
  +Index: work.cc
  +--- work.cc  9c9fd46396607ec971ccf77b6dbdfe54934b9ec5
  ++++ work.cc  0261cdf7dbc3baed0cdfc0e75a3a858f64eefa97
  +@@ -180,7 +180,7 @@ workspace::workspace(app_state & app, i1
  +     set_ws_options(app.opts, false);
  + }
  + 
  +-workspace::workspace(options const & opts, lua_hooks & lua, 
  ++workspace::workspace(options const & opts, lua_hooks & lua,
  +                      i18n_format const & explanation, bool 
writeback_options)
  +   : lua(lua)
  + {
  +@@ -509,9 +509,15 @@ workspace::set_ws_options(options const 
  +     read_options_file(o_path,
  +                       database_option, branch_option, key_option, 
keydir_option);
  + 
  +-  if (!opts.dbname.as_internal().empty())
  ++    // FIXME: we should do more checks here, f.e. if this is a valid sqlite
  ++    // file and if it contains the correct identifier, but these checks 
would
  ++    // duplicate those in database.cc. At the time it is checked there, 
however,
  ++    // the options file for the workspace is already written out...
  ++  if (!opts.dbname.as_internal().empty() &&
  ++      get_path_status(opts.dbname.as_internal()) == path::file)
  +     database_option = opts.dbname;
  +-  if (!opts.key_dir.as_internal().empty())
  ++  if (!opts.key_dir.as_internal().empty() &&
  ++      get_path_status(opts.key_dir.as_internal()) == path::directory)
  +     keydir_option = opts.key_dir;
  +   if ((branch_is_sticky || workspace::branch_is_sticky)
  +       && !opts.branchname().empty())
  +@@ -1570,8 +1576,8 @@ workspace::perform_rename(database & db,
  +           // touch foo
  +           // mtn mv foo bar/foo where bar doesn't exist
  +           file_path parent = dst.dirname();
  +-            N(get_path_status(parent) == path::directory,
  +-              F("destination path's parent directory %s/ doesn't exist") % 
parent);
  ++            N(get_path_status(parent) == path::directory,
  ++              F("destination path's parent directory %s/ doesn't exist") % 
parent);
  +         }
  + 
  +       renames.insert(make_pair(src, dpath));
  +
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/monotone/monotone.spec
  ============================================================================
  $ cvs diff -u -r1.34 -r1.35 monotone.spec
  --- openpkg-src/monotone/monotone.spec        14 Apr 2008 18:26:47 -0000      
1.34
  +++ openpkg-src/monotone/monotone.spec        17 Apr 2008 05:59:42 -0000      
1.35
  @@ -32,7 +32,7 @@
   Group:        SCM
   License:      GPL
   Version:      0.40
  -Release:      20080414
  +Release:      20080417
   
   #   package options
   %option       with_rse  yes
  @@ .
______________________________________________________________________
OpenPKG                                             http://openpkg.org
CVS Repository Commit List                     [email protected]

Reply via email to