lldir.cpp 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736
  1. /**
  2. * @file lldir.cpp
  3. * @brief Implementation of directory utilities base class
  4. *
  5. * $LicenseInfo:firstyear=2002&license=viewergpl$
  6. *
  7. * Copyright (c) 2002-2009, Linden Research, Inc.
  8. *
  9. * Second Life Viewer Source Code
  10. * The source code in this file ("Source Code") is provided by Linden Lab
  11. * to you under the terms of the GNU General Public License, version 2.0
  12. * ("GPL"), unless you have obtained a separate licensing agreement
  13. * ("Other License"), formally executed by you and Linden Lab. Terms of
  14. * the GPL can be found in doc/GPL-license.txt in this distribution, or
  15. * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
  16. *
  17. * There are special exceptions to the terms and conditions of the GPL as
  18. * it is applied to this Source Code. View the full text of the exception
  19. * in the file doc/FLOSS-exception.txt in this software distribution, or
  20. * online at
  21. * http://secondlifegrid.net/programs/open_source/licensing/flossexception
  22. *
  23. * By copying, modifying or distributing this software, you acknowledge
  24. * that you have read and understood your obligations described above,
  25. * and agree to abide by those obligations.
  26. *
  27. * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
  28. * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
  29. * COMPLETENESS OR PERFORMANCE.
  30. * $/LicenseInfo$
  31. */
  32. #include "linden_common.h"
  33. #if LL_WINDOWS
  34. # include <direct.h>
  35. #else
  36. # include <sys/stat.h>
  37. # include <sys/types.h>
  38. # include <errno.h>
  39. #endif
  40. #include "lldir.h"
  41. LLDir gDirUtil;
  42. LLDir::LLDir()
  43. : mUsingDefaultSkin(false)
  44. {
  45. init();
  46. }
  47. std::string LLDir::findFile(const std::string& filename,
  48. const std::string& path1,
  49. const std::string& path2,
  50. const std::string& path3,
  51. const std::string& path4) const
  52. {
  53. std::vector<std::string> search_paths;
  54. search_paths.push_back(path1);
  55. search_paths.push_back(path2);
  56. search_paths.push_back(path3);
  57. search_paths.push_back(path4);
  58. std::string fullpath;
  59. for (S32 i = 0, count = search_paths.size(); i < count; ++i)
  60. {
  61. fullpath = search_paths[i];
  62. if (!fullpath.empty())
  63. {
  64. fullpath += LL_DIR_DELIM_STR + filename;
  65. if (LLFile::exists(fullpath))
  66. {
  67. return fullpath;
  68. }
  69. }
  70. }
  71. return LLStringUtil::null;
  72. }
  73. std::string LLDir::getCacheDir(bool get_default) const
  74. {
  75. if (mCacheDir.empty() || get_default)
  76. {
  77. if (!mDefaultCacheDir.empty())
  78. {
  79. // Set at startup: cannot set here due to const API
  80. return mDefaultCacheDir;
  81. }
  82. std::string res = buildSLOSCacheDir();
  83. return res;
  84. }
  85. return mCacheDir;
  86. }
  87. // Return the default cache directory
  88. std::string LLDir::buildSLOSCacheDir() const
  89. {
  90. if (mOSCacheDir.empty())
  91. {
  92. if (mOSUserAppDir.empty())
  93. {
  94. return "data";
  95. }
  96. else
  97. {
  98. return mOSUserAppDir + LL_DIR_DELIM_STR + "cache_coolvlviewer";
  99. }
  100. }
  101. return mOSCacheDir + LL_DIR_DELIM_STR + "CoolVLViewer";
  102. }
  103. std::string LLDir::getSkinBaseDir() const
  104. {
  105. return mAppRODataDir + LL_DIR_DELIM_STR + "skins";
  106. }
  107. std::string LLDir::getFullPath(ELLPath location, const std::string& subdir1,
  108. const std::string& subdir2,
  109. const std::string& in_filename) const
  110. {
  111. std::string prefix;
  112. switch (location)
  113. {
  114. case LL_PATH_NONE:
  115. // Do nothing
  116. break;
  117. case LL_PATH_APP_SETTINGS:
  118. prefix = mAppRODataDir + LL_DIR_DELIM_STR + "app_settings";
  119. break;
  120. case LL_PATH_CHARACTER:
  121. prefix = mAppRODataDir + LL_DIR_DELIM_STR + "character";
  122. break;
  123. #if 0
  124. case LL_PATH_MOTIONS:
  125. prefix = mAppRODataDir + LL_DIR_DELIM_STR + "motions";
  126. break;
  127. #endif
  128. case LL_PATH_HELP:
  129. prefix = "help";
  130. break;
  131. case LL_PATH_CACHE:
  132. prefix = getCacheDir();
  133. break;
  134. case LL_PATH_USER_SETTINGS:
  135. prefix = mOSUserAppDir + LL_DIR_DELIM_STR + "user_settings";
  136. break;
  137. case LL_PATH_PER_ACCOUNT:
  138. prefix = mLindenUserDir;
  139. break;
  140. case LL_PATH_CHAT_LOGS:
  141. prefix = mChatLogsDir;
  142. break;
  143. case LL_PATH_PER_ACCOUNT_CHAT_LOGS:
  144. prefix = mPerAccountChatLogsDir;
  145. break;
  146. case LL_PATH_LOGS:
  147. prefix = mOSUserAppDir + LL_DIR_DELIM_STR + "logs";
  148. break;
  149. case LL_PATH_TEMP:
  150. prefix = mTempDir;
  151. break;
  152. case LL_PATH_TOP_SKIN:
  153. prefix = mSkinDir;
  154. break;
  155. case LL_PATH_SKINS:
  156. prefix = mAppRODataDir + LL_DIR_DELIM_STR + "skins";
  157. break;
  158. case LL_PATH_EXECUTABLE:
  159. prefix = mExecutableDir;
  160. break;
  161. default:
  162. llwarns << "Invalid ELLPath number: " << location << llendl;
  163. llassert(false);
  164. }
  165. std::string filename = in_filename;
  166. if (!subdir2.empty())
  167. {
  168. filename = subdir2 + LL_DIR_DELIM_STR + filename;
  169. }
  170. if (!subdir1.empty())
  171. {
  172. filename = subdir1 + LL_DIR_DELIM_STR + filename;
  173. }
  174. std::string expanded_filename;
  175. if (!filename.empty())
  176. {
  177. if (!prefix.empty())
  178. {
  179. expanded_filename += prefix + LL_DIR_DELIM_STR + filename;
  180. }
  181. else
  182. {
  183. expanded_filename = filename;
  184. }
  185. }
  186. else if (!prefix.empty())
  187. {
  188. // Directory only, no file name.
  189. expanded_filename = prefix;
  190. }
  191. else
  192. {
  193. expanded_filename.clear();
  194. }
  195. return expanded_filename;
  196. }
  197. std::string LLDir::getBaseFileName(const std::string& filepath,
  198. bool strip_exten) const
  199. {
  200. std::size_t offset = filepath.find_last_of(LL_DIR_DELIM_CHR);
  201. offset = offset == std::string::npos ? 0 : offset + 1;
  202. std::string res = filepath.substr(offset);
  203. if (strip_exten)
  204. {
  205. // If basename STARTS with '.', do not strip
  206. offset = res.find_last_of('.');
  207. if (offset != std::string::npos && offset != 0)
  208. {
  209. res = res.substr(0, offset);
  210. }
  211. }
  212. return res;
  213. }
  214. std::string LLDir::getDirName(const std::string& filepath) const
  215. {
  216. std::size_t offset = filepath.find_last_of(LL_DIR_DELIM_CHR);
  217. S32 len = (offset == std::string::npos) ? 0 : offset;
  218. return filepath.substr(0, len);
  219. }
  220. std::string LLDir::getExtension(const std::string& filepath) const
  221. {
  222. std::string exten;
  223. if (!filepath.empty())
  224. {
  225. std::string basename = getBaseFileName(filepath, false);
  226. std::size_t offset = basename.find_last_of('.');
  227. if (offset != std::string::npos && offset != 0)
  228. {
  229. exten = basename.substr(offset + 1);
  230. LLStringUtil::toLower(exten);
  231. }
  232. }
  233. return exten;
  234. }
  235. bool LLDir::isRelativePath(const std::string& path) const
  236. {
  237. if (path.empty()) return false;
  238. if (path == ".." ||
  239. #if LL_WINDOWS // Also check for UNIX style paths...
  240. path.find("../") != std::string::npos ||
  241. path.find("/..") != std::string::npos ||
  242. #endif
  243. path.find(".." LL_DIR_DELIM_STR) != std::string::npos ||
  244. path.find(LL_DIR_DELIM_STR "..") != std::string::npos)
  245. {
  246. llwarns << "Skipping relative path: " << path << llendl;
  247. return true;
  248. }
  249. return false;
  250. }
  251. bool LLDir::hasSkin(const char* skin_folder) const
  252. {
  253. std::string colors(LL_DIR_DELIM_STR "skins" LL_DIR_DELIM_STR);
  254. colors.append(skin_folder);
  255. colors.append(LL_DIR_DELIM_STR "colors_base.xml");
  256. return LLFile::exists(mAppRODataDir + colors) ||
  257. LLFile::exists(mOSUserAppDir + colors);
  258. }
  259. std::string LLDir::findSkinnedFilename(const std::string& filename) const
  260. {
  261. return findSkinnedFilename(LLStringUtil::null, LLStringUtil::null,
  262. filename);
  263. }
  264. std::string LLDir::findSkinnedFilename(const std::string& subdir,
  265. const std::string& filename) const
  266. {
  267. std::string ret;
  268. if (!isRelativePath(subdir))
  269. {
  270. ret = findSkinnedFilename(LLStringUtil::null, subdir, filename);
  271. }
  272. return ret;
  273. }
  274. std::string LLDir::findSkinnedFilename(const std::string& subdir1,
  275. const std::string& subdir2,
  276. const std::string& filename) const
  277. {
  278. if (isRelativePath(subdir1) || isRelativePath(subdir2))
  279. {
  280. return "";
  281. }
  282. // Generate subdirectory path fragment, e.g. "/foo/bar", "/foo", ""
  283. std::string subdirs;
  284. if (!subdir1.empty())
  285. {
  286. subdirs = LL_DIR_DELIM_STR + subdir1;
  287. }
  288. if (!subdir2.empty())
  289. {
  290. subdirs += LL_DIR_DELIM_STR + subdir2;
  291. }
  292. if (mUsingDefaultSkin)
  293. {
  294. return findFile(filename,
  295. mUserSkinDir + subdirs, // First in user skin override
  296. mSkinDir + subdirs); // Then in current skin
  297. }
  298. return findFile(filename,
  299. mUserSkinDir + subdirs, // First in user skin override
  300. mSkinDir + subdirs, // Then in current skin
  301. // Then in default user skin override
  302. mUserDefaultSkinDir + subdirs,
  303. mDefaultSkinDir + subdirs); // And last in default skin
  304. }
  305. std::string LLDir::getTempFilename(bool with_extension) const
  306. {
  307. LLUUID random_uuid;
  308. random_uuid.generate();
  309. std::string filename = mTempDir + LL_DIR_DELIM_STR +
  310. random_uuid.asString();
  311. if (with_extension)
  312. {
  313. filename += ".tmp";
  314. }
  315. return filename;
  316. }
  317. std::string LLDir::getUserFilename(std::string desired_subdir,
  318. std::string fallback_subdir,
  319. std::string filename)
  320. {
  321. if (filename.front() == '/' ||
  322. #if LL_WINDOWS
  323. filename.front() == LL_DIR_DELIM_CHR ||
  324. filename.back() == LL_DIR_DELIM_CHR ||
  325. #endif
  326. filename.back() == '/')
  327. {
  328. llwarns << "Invalid path separator position for a file name: "
  329. << filename << llendl;
  330. return LLStringUtil::null;
  331. }
  332. // Check for sub-directory name(s) in the file name.
  333. size_t i = filename.rfind('/');
  334. if (i != std::string::npos)
  335. {
  336. if (desired_subdir.back() != '/')
  337. {
  338. desired_subdir += '/';
  339. }
  340. desired_subdir += filename.substr(0, i);
  341. if (!fallback_subdir.empty())
  342. {
  343. if (fallback_subdir.back() != '/')
  344. {
  345. fallback_subdir += '/';
  346. }
  347. fallback_subdir += filename.substr(0, i);
  348. }
  349. filename = filename.substr(i + 1);
  350. }
  351. // Sanitize the filename to remove forbidden characters
  352. filename = getScrubbedFileName(filename);
  353. if (filename.empty())
  354. {
  355. // No need to proceed farther...
  356. return filename;
  357. }
  358. std::string fullpath, subdir;
  359. if (!desired_subdir.empty())
  360. {
  361. // Sanitize the directory name to remove forbidden characters and paths
  362. subdir = getScrubbedDirName(desired_subdir);
  363. // Remove all "current directory" path elements
  364. LLStringUtil::replaceString(subdir, "." LL_DIR_DELIM_STR, "");
  365. if (!subdir.empty())
  366. {
  367. if (subdir.find("~" LL_DIR_DELIM_STR) == 0)
  368. {
  369. // We search in the user home directory
  370. subdir = mOSUserDir + subdir.substr(1);
  371. if (subdir.back() != LL_DIR_DELIM_CHR)
  372. {
  373. fullpath = subdir + LL_DIR_DELIM_STR + filename;
  374. }
  375. else
  376. {
  377. fullpath = subdir + filename;
  378. }
  379. if (LLFile::exists(fullpath))
  380. {
  381. return fullpath; // Success
  382. }
  383. fullpath.clear(); // Failed
  384. // Sanitize the directory name to remove forbidden characters
  385. // and paths
  386. subdir = getScrubbedDirName(fallback_subdir);
  387. if (!subdir.empty())
  388. {
  389. if (subdir.back() != LL_DIR_DELIM_CHR)
  390. {
  391. fullpath = subdir + LL_DIR_DELIM_STR + filename;
  392. }
  393. else
  394. {
  395. fullpath = subdir + filename;
  396. }
  397. if (!LLFile::exists(fullpath))
  398. {
  399. fullpath.clear(); // Failed
  400. }
  401. }
  402. return fullpath;
  403. }
  404. // We search in the Secondlife user settings directory, per account
  405. // first, then global.
  406. fullpath = getFullPath(LL_PATH_PER_ACCOUNT, subdir, filename);
  407. if (!LLFile::exists(fullpath))
  408. {
  409. fullpath = getFullPath(LL_PATH_USER_SETTINGS, subdir,
  410. filename);
  411. if (!LLFile::exists(fullpath))
  412. {
  413. fullpath.clear(); // Failed
  414. }
  415. }
  416. }
  417. }
  418. if (fullpath.empty())
  419. {
  420. // Sanitize the directory name to remove forbidden characters and paths
  421. subdir = getScrubbedDirName(fallback_subdir);
  422. if (!subdir.empty())
  423. {
  424. fullpath = getFullPath(LL_PATH_PER_ACCOUNT, subdir, filename);
  425. if (!LLFile::exists(fullpath))
  426. {
  427. fullpath = getFullPath(LL_PATH_USER_SETTINGS, subdir,
  428. filename);
  429. if (!LLFile::exists(fullpath))
  430. {
  431. fullpath.clear(); // Failed
  432. }
  433. }
  434. }
  435. }
  436. return fullpath;
  437. }
  438. //static
  439. std::string LLDir::getForbiddenDirChars()
  440. {
  441. return ":*?\"<>|";
  442. }
  443. //static
  444. std::string LLDir::getForbiddenFileChars()
  445. {
  446. return "\\/:*?\"<>|";
  447. }
  448. //static
  449. std::string LLDir::getScrubbedDirName(const std::string& dirname)
  450. {
  451. std::string cleanname = dirname;
  452. // Use the proper directory delimiter everywhere in name and remove parent
  453. // directory symbols to forbid navigating upwards in the file system.
  454. #if LL_WINDOWS
  455. LLStringUtil::replaceChar(cleanname, '/', '\\');
  456. LLStringUtil::replaceString(cleanname, "..\\", "");
  457. #else
  458. LLStringUtil::replaceChar(cleanname, '\\', '/');
  459. LLStringUtil::replaceString(cleanname, "../", "");
  460. #endif
  461. const std::string illegal_chars = getForbiddenDirChars();
  462. // Replace any illegal directory chararacter with an underscore '_'
  463. for (size_t i = 0, count = illegal_chars.length(); i < count; ++i)
  464. {
  465. const char& c = illegal_chars[i];
  466. size_t j = 0;
  467. while ((j = cleanname.find(c, j)) != std::string::npos)
  468. {
  469. cleanname[j++] = '_';
  470. }
  471. }
  472. return cleanname;
  473. }
  474. //static
  475. std::string LLDir::getScrubbedFileName(const std::string& filename)
  476. {
  477. std::string cleanname = filename;
  478. const std::string illegal_chars = getForbiddenFileChars();
  479. // Replace any illegal file chararacter with an underscore '_'
  480. for (size_t i = 0, count = illegal_chars.length(); i < count; ++i)
  481. {
  482. const char& c = illegal_chars[i];
  483. size_t j = 0;
  484. while ((j = cleanname.find(c, j)) != std::string::npos)
  485. {
  486. cleanname[j++] = '_';
  487. }
  488. }
  489. return cleanname;
  490. }
  491. void LLDir::setLindenUserDir(const std::string& grid, const std::string& first,
  492. const std::string& last)
  493. {
  494. // If both first and last are not set, assume we are grabbing the cached
  495. // directory
  496. if (!first.empty() && !last.empty())
  497. {
  498. // Some platforms have case-sensitive filesystems, so be utterly
  499. // consistent with our firstname/lastname case.
  500. std::string fnlc = first;
  501. LLStringUtil::toLower(fnlc);
  502. std::string lnlc = last;
  503. LLStringUtil::toLower(lnlc);
  504. mLindenUserDir = mOSUserAppDir + LL_DIR_DELIM_STR + fnlc + "_" + lnlc;
  505. // Append the name of the grid, but only when not in SL to stay upward
  506. // compatible with SL viewers.
  507. if (!grid.empty())
  508. {
  509. std::string gridlc = getScrubbedFileName(grid);
  510. LLStringUtil::toLower(gridlc);
  511. if (gridlc.find("secondlife") == std::string::npos)
  512. {
  513. if (gridlc == "none" || gridlc == "other")
  514. {
  515. // Unknown grid name...
  516. gridlc = "unknown";
  517. }
  518. mLindenUserDir += "@" + gridlc;
  519. }
  520. }
  521. }
  522. else
  523. {
  524. llwarns << "Invalid name for User Dir, adopting: unknown_user"
  525. << llendl;
  526. mLindenUserDir = mOSUserAppDir + LL_DIR_DELIM_STR + "unknown_user";
  527. }
  528. dumpCurrentDirectories();
  529. }
  530. void LLDir::setChatLogsDir(const std::string& path)
  531. {
  532. if (!path.empty())
  533. {
  534. mChatLogsDir = path;
  535. }
  536. else
  537. {
  538. llwarns << "Invalid (emtpy) path name" << llendl;
  539. }
  540. dumpCurrentDirectories();
  541. }
  542. void LLDir::setPerAccountChatLogsDir(const std::string& grid,
  543. const std::string& first,
  544. const std::string& last)
  545. {
  546. // If both first and last are not set, assume we are grabbing the cached
  547. // directory
  548. if (!first.empty() && !last.empty())
  549. {
  550. // some platforms have case-sensitive filesystems, so be
  551. // utterly consistent with our firstname/lastname case.
  552. std::string fnlc(first);
  553. LLStringUtil::toLower(fnlc);
  554. std::string lnlc(last);
  555. LLStringUtil::toLower(lnlc);
  556. mPerAccountChatLogsDir = mChatLogsDir + LL_DIR_DELIM_STR + fnlc + "_" +
  557. lnlc;
  558. // Append the name of the grid, but only when not in SL to stay upward
  559. // compatible with SL viewers.
  560. if (!grid.empty())
  561. {
  562. std::string gridlc = getScrubbedFileName(grid);
  563. LLStringUtil::toLower(gridlc);
  564. if (gridlc.find("secondlife") == std::string::npos)
  565. {
  566. if (gridlc == "none" || gridlc == "other")
  567. {
  568. // Unknown grid name...
  569. gridlc = "unknown";
  570. }
  571. mPerAccountChatLogsDir += "@" + gridlc;
  572. }
  573. }
  574. }
  575. else
  576. {
  577. llwarns << "Invalid name: " << (first.empty() ? "first" : "last")
  578. << " name is empty !" << llendl;
  579. }
  580. dumpCurrentDirectories();
  581. }
  582. void LLDir::setSkinFolder(const std::string& skin_folder)
  583. {
  584. mSkinDir = mAppRODataDir + LL_DIR_DELIM_STR + "skins" + LL_DIR_DELIM_STR +
  585. skin_folder;
  586. // User overrides to current skin e.g. ~/.secondlife/skins/silver
  587. mUserSkinDir = mOSUserAppDir + LL_DIR_DELIM_STR + "skins" +
  588. LL_DIR_DELIM_STR + skin_folder;
  589. // User overrides to current skin e.g. ~/.secondlife/skins/default
  590. mUserDefaultSkinDir = mOSUserAppDir + LL_DIR_DELIM_STR + "skins" +
  591. LL_DIR_DELIM_STR + "default";
  592. // Base skin which is used as fallback for all skinned files e.g.
  593. // c:\program files\secondlife\skins\default
  594. mDefaultSkinDir = mAppRODataDir + LL_DIR_DELIM_STR + "skins" +
  595. LL_DIR_DELIM_STR + "default";
  596. mUsingDefaultSkin = skin_folder == "default";
  597. dumpCurrentDirectories();
  598. }
  599. bool LLDir::setCacheDir(const std::string& path)
  600. {
  601. bool success = false;
  602. if (path.empty())
  603. {
  604. // Reset to default
  605. mCacheDir.clear();
  606. success = true;
  607. }
  608. else
  609. {
  610. LLFile::mkdir(path);
  611. std::string tempname = path + LL_DIR_DELIM_STR + "temp";
  612. LLFILE* file = LLFile::open(tempname, "wt");
  613. if (file)
  614. {
  615. LLFile::close(file);
  616. LLFile::remove(tempname);
  617. mCacheDir = path;
  618. success = true;
  619. }
  620. }
  621. dumpCurrentDirectories();
  622. return success;
  623. }
  624. void LLDir::dumpCurrentDirectories()
  625. {
  626. LL_DEBUGS("AppInit") << "Current Directories:" << LL_ENDL;
  627. LL_DEBUGS("AppInit") << " CurPath: "
  628. << getCurPath() << LL_ENDL;
  629. LL_DEBUGS("AppInit") << " AppName: "
  630. << mAppName << LL_ENDL;
  631. LL_DEBUGS("AppInit") << " ExecutableFilename: "
  632. << mExecutableFilename << LL_ENDL;
  633. LL_DEBUGS("AppInit") << " ExecutableDir: "
  634. << mExecutableDir << LL_ENDL;
  635. LL_DEBUGS("AppInit") << " ExecutablePathAndName: "
  636. << mExecutablePathAndName << LL_ENDL;
  637. LL_DEBUGS("AppInit") << " LLPluginDir: "
  638. << mLLPluginDir << LL_ENDL;
  639. LL_DEBUGS("AppInit") << " WorkingDir: "
  640. << mWorkingDir << LL_ENDL;
  641. LL_DEBUGS("AppInit") << " AppRODataDir: "
  642. << mAppRODataDir << LL_ENDL;
  643. LL_DEBUGS("AppInit") << " OSUserDir: "
  644. << mOSUserDir << LL_ENDL;
  645. LL_DEBUGS("AppInit") << " OSUserAppDir: "
  646. << mOSUserAppDir << LL_ENDL;
  647. LL_DEBUGS("AppInit") << " LindenUserDir: "
  648. << mLindenUserDir << LL_ENDL;
  649. LL_DEBUGS("AppInit") << " ChatLogsDir: "
  650. << mChatLogsDir << LL_ENDL;
  651. LL_DEBUGS("AppInit") << " PerAccountChatLogsDir: "
  652. << mPerAccountChatLogsDir << LL_ENDL;
  653. LL_DEBUGS("AppInit") << " TempDir: "
  654. << mTempDir << LL_ENDL;
  655. LL_DEBUGS("AppInit") << " CRTFile: "
  656. << mCRTFile << LL_ENDL;
  657. LL_DEBUGS("AppInit") << " SkinDir: "
  658. << mSkinDir << LL_ENDL;
  659. LL_DEBUGS("AppInit") << " OSCacheDir: "
  660. << mOSCacheDir << LL_ENDL;
  661. }