| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Simon L <szaimen@e.mail.de>
|
|
|
|
| |
config file.
|
|
|
|
| |
Signed-off-by: Simon L <szaimen@e.mail.de>
|
|
|
|
| |
Signed-off-by: Simon L <szaimen@e.mail.de>
|
| |
|
|\
| |
| | |
Make config file saving safe against write failures
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In case of disk space depletion, writing a new version of config fails,
leaving the config file empty.
This patch improves safety of updates to config.php by saving the new
version of the config into a randomly-named temporary file in the same
directory, and then renaming it to config.php, which renaming is atomic
in POSIX-compliant filesystems and shouldn't involve disk space
allocation. If writing the new config version is impossible, the current
config remains unchanged.
This patch drops the use of file locking as unnecessary. File locking
merely established order in which the concurrent independent processes
attempted file writing. In the end, the process which was last to update
the file "wins" - their changes persist and the changes of previous
writers are dropped as there's no conflict detection or change merging
mechanism anyway. With the current change, there is still some resulting
ordering, and the last writer still wins in the same way. Readers don't
need file locking as well, as opening config.php for reading always
provides a certain consistent version of the file.
Signed-off-by: Andriy Utkin <dev@autkin.net>
|
|/
|
|
| |
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
|
|
|
|
|
|
|
| |
Because those will cause PHP to output to stdout and will cause
unrelated error messages.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
|
|
|
|
|
|
|
|
| |
Also don't write to cache in this case to prevent cache and config file
being out of sync.
Fixes: #29901
Signed-off-by: Jonas Meurer <jonas@freesources.org>
|
|
|
|
| |
Signed-off-by: Gary Kim <gary@garykim.dev>
|
|
|
|
| |
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
|
|
|
| |
We read config.php an awefull lot of times. So it only makes sense to
kill this as much as wel can.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|\
| |
| | |
Update the license headers for Nextcloud 19
|
| |
| |
| |
| | |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|/ |
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
| |
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
|
|
|
|
|
|
|
|
|
|
|
| |
* Order the imports
* No leading slash on imports
* Empty line before namespace
* One line per import
* Empty after imports
* Emmpty line at bottom of file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
|
|
|
|
| |
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
|
|
|
|
| |
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
|
|
|
| |
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
|
|
|
|
|
| |
* fixes #4655
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
|
|
|
| |
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
|
|
|
| |
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
|
|
|
|
|
|
|
| |
* added functionality to override config.php values with 'OC_' prefixed environment variables
* use getenv to read environment variables since apache does not set $_ENV variables, fixed test
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
|
| |
|
| |
|
|
|
|
|
|
| |
* when the config file is not writable there is a error message shown
* same happens now if the config file is not readable
* fixes #180
|
| |
|
|
* \OC\ActivityManager
* \OC\AllConfig
* \OC\AppConfig
* \OC\AppHelper
* \OC\Avatar
* \OC\AvatarManager
* \OC\CapabilitiesManager
* \OC\Config
* \OC\ContactsManager
* \OC\DatabaseException
* \OC\DatabaseSetupException
|