Menu

[r9]: / trunk / src / SVN.cpp  Maximize  Restore  History

Download this file

48 lines (39 with data), 1.2 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#include "StdAfx.h"
#include "svn.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
SVN::SVN(void)
{
parentpool = svn_pool_create(NULL);
svn_client_create_context(&m_pctx, parentpool);
Err = svn_config_ensure(NULL, parentpool);
pool = svn_pool_create (parentpool);
// set up the configuration
//if (Err == 0)
// Err = svn_config_get_config (&(m_pctx->config), g_pConfigDir, parentpool);
if (Err != 0)
{
//::MessageBox(NULL, this->GetLastErrorMessage(), _T("TortoiseSVN"), MB_ICONERROR);
svn_pool_destroy (pool);
svn_pool_destroy (parentpool);
exit(-1);
}
//set up the SVN_SSH param
//CString tsvn_ssh = CRegString(_T("Software\\TortoiseSVN\\SSH"));
//if (tsvn_ssh.IsEmpty())
// tsvn_ssh = CPathUtils::GetAppDirectory() + _T("TortoisePlink.exe");
//tsvn_ssh.Replace('\\', '/');
//if (!tsvn_ssh.IsEmpty())
//{
// svn_config_t * cfg = (svn_config_t *)apr_hash_get (m_pctx->config, SVN_CONFIG_CATEGORY_CONFIG,
// APR_HASH_KEY_STRING);
// svn_config_set(cfg, SVN_CONFIG_SECTION_TUNNELS, "ssh", CUnicodeUtils::GetUTF8(tsvn_ssh));
//}
}
SVN::~SVN(void)
{
svn_pool_destroy (parentpool);
}
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.