Menu

#21 createRepository fails in windows

open
nobody
None
5
2010-01-13
2010-01-13
Mark Nettle
No

There's no check for running on windows in createRepository (RepostitoryModule/DataModule.php), hence
exec("LANG=".$lang."; ...
at line 72 fails

This failure isn't caught for some reason - think this is mentioned in a different bug.

Nearby, line 68 should put $a_dir in the log, not $dir

Discussion

  • Nobody/Anonymous

    I have the same Problem on Windows 2003 Server. The exec command won't execute the svnadmin-command.
    Little Debugging show's me, that $a_dir has a string like: c:\svnrepos\"testrepo" ...
    the quotationmarks seams to be wrong.

    i removed the escapeshellarg from
    $a_dir = $svn_repos_loc.DIRECTORY_SEPARATOR.escapeshellarg($rname);
    to $a_dir = $svn_repos_loc.DIRECTORY_SEPARATOR.$rname;

    also in the exec-command i removed the "LANG=".$lang."; part....

    this works for me under Win Server 2003. Maybe this could be fatal on linux/unix based systems?

     
  • cforge leader

    cforge leader - 2011-01-19

    svsmanage/RepositoryModule/DataModule.php
    [1]
    from
    $a_dir = $svn_repos_loc.DIRECTORY_SEPARATOR.escapeshellarg($rname);
    to $a_dir = escapeshellarg($svn_repos_loc.DIRECTORY_SEPARATOR.$rname);
    [2]
    if(getenv("OS")=="Windows_NT") {
    $ret = exec("$svnadmin_cmd --config-dir $svn_config_dir create $a_dir");
    } else {
    $ret = exec("LANG=".$lang.";$svnadmin_cmd --config-dir $svn_config_dir create $a_dir");
    }
    }

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.