SyncDlg: Use one repository instance in FillNewRefMap

Signed-off-by: Sven Strickroth <email@cs-ware.de>
Signed-off-by: Sup Yut Sum <ch3cooli@gmail.com>
Move some logic for getting config values to CAutoConfig

Signed-off-by: Sven Strickroth <email@cs-ware.de>
Initialize members

Signed-off-by: Sven Strickroth <email@cs-ware.de>
Add length check

Signed-off-by: Sven Strickroth <email@cs-ware.de>
Ensure the app directory path is properly canonicalized

Based on TortoiseSVN revision 25492

Signed-off-by: Sup Yut Sum <ch3cooli@gmail.com>