comparison cinst/mozilla.c @ 988:ca89cf228a5b

(issue86) Write nss shared db defaults into /etc/skel
author Andre Heinecke <andre.heinecke@intevation.de>
date Fri, 29 Aug 2014 18:35:56 +0200
parents 66f6361fba1b
children 1cd1bfe82fc2
comparison
equal deleted inserted replaced
987:b8ae69bcc540 988:ca89cf228a5b
80 #ifndef _WIN32 80 #ifndef _WIN32
81 #define CONFDIRS ".mozilla", ".thunderbird" 81 #define CONFDIRS ".mozilla", ".thunderbird"
82 /* Default installation directory of ubuntu 14.4 is respected */ 82 /* Default installation directory of ubuntu 14.4 is respected */
83 #define MOZILLA_DEFAULTS "/etc/thunderbird", "/etc/firefox" 83 #define MOZILLA_DEFAULTS "/etc/thunderbird", "/etc/firefox"
84 #define NSSSHARED ".pki/nssdb" 84 #define NSSSHARED ".pki/nssdb"
85 #define NSSSHARED_GLOBAL "/etc/pki/nssdb" 85 #define NSSSHARED_GLOBAL "/etc/skel/.pki/nssdb"
86 #define TARGET_LINUX 1 86 #define TARGET_LINUX 1
87 #define DIRSEP "/" 87 #define DIRSEP "/"
88 #else 88 #else
89 #define MOZILLA_DEFAULTS "Mozilla Firefox\\browser\\defaults", "Mozilla Thunderbird\\defaults" 89 #define MOZILLA_DEFAULTS "Mozilla Firefox\\browser\\defaults", "Mozilla Thunderbird\\defaults"
90 #define CONFDIRS "Mozilla", "Thunderbird" 90 #define CONFDIRS "Mozilla", "Thunderbird"
406 406
407 if (is_elevated()) 407 if (is_elevated())
408 { 408 {
409 #ifndef _WIN32 409 #ifndef _WIN32
410 /* NSS Shared db does not exist under windows. */ 410 /* NSS Shared db does not exist under windows. */
411 strv_append(&alldirs, NSSSHARED_GLOBAL, strlen(NSSSHARED_GLOBAL)); 411 if (!port_mkdir_p(NSSSHARED_GLOBAL))
412 {
413 ERRORPRINTF("Failed to create nssshared skeleton directory. \n");
414 }
415 else
416 {
417 strv_append(&alldirs, "sql:" NSSSHARED_GLOBAL, strlen("sql:" NSSSHARED_GLOBAL));
418 }
412 #endif 419 #endif
413 pdirs = get_default_profile_dirs(); 420 pdirs = get_default_profile_dirs();
414 if (pdirs != NULL) 421 if (pdirs != NULL)
415 { 422 {
416 for (int i=0; pdirs[i] != NULL; i++) 423 for (int i=0; pdirs[i] != NULL; i++)

http://wald.intevation.org/projects/trustbridge/