aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main.cpp
diff options
context:
space:
mode:
authorVaxry <[email protected]>2024-04-28 22:25:24 +0100
committerGitHub <[email protected]>2024-04-28 22:25:24 +0100
commita5a648091760ac002120fab18247e5292b6482de (patch)
tree0fd68dff8db4277bd2d030867628cbb48f63ce7c /src/main.cpp
parentd20ee312108d0e7879011cfffa3a83d06e48d29e (diff)
downloadHyprland-a5a648091760ac002120fab18247e5292b6482de.tar.gz
Hyprland-a5a648091760ac002120fab18247e5292b6482de.zip
core: Move /tmp/hypr to $XDG_RUNTIME_DIR/hypr (#5788)
Moves the directory containing sockets and logs. Also restructures lockfiles a bit. For consumers, check if `$XDG_RUNTIME_DIR/hypr` exists. If so, use it. If not, use the old `/tmp/hypr`.
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp
index e1f43ad0..7e6fee02 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -97,8 +97,13 @@ int main(int argc, char** argv) {
// let's init the compositor.
// it initializes basic Wayland stuff in the constructor.
- g_pCompositor = std::make_unique<CCompositor>();
- g_pCompositor->explicitConfigPath = configPath;
+ try {
+ g_pCompositor = std::make_unique<CCompositor>();
+ g_pCompositor->explicitConfigPath = configPath;
+ } catch (std::exception& e) {
+ std::cout << "Hyprland threw in ctor: " << e.what() << "\nCannot continue.\n";
+ return 1;
+ }
g_pCompositor->initServer();