Comments (4)
should be fixed with 7ae1d1d and bec451e
lmk
from hyprpicker.
bec451e snapshot still crashes:
Clang backtrace
$ export CC=clang CXX=clang++ CXXFLAGS=-stdlib=libc++
$ cmake -G Ninja -B /tmp/hyprpicker_build
$ cmake --build /tmp/hyprpicker_build
$ cmake --install /tmp/hyprpicker_build
$ hyprpicker
<press ESC to exit>
Segmentation fault
* thread #1, name = 'hyprpicker', stop reason = signal SIGSEGV: invalid address (fault address: 0x1c)
frame #0: 0x00000008229f1858 libwayland-client.so.0`wl_map_insert_at(map=0x0000000837b7f080, flags=1, i=3, data=0x0000000000000000) at wayland-util.c:275:16
272 }
273
274 start = entries->data;
-> 275 start[i].data = data;
276 start[i].next |= (flags & 0x1) << 1;
277
278 return 0;
(lldb) bt
* thread #1, name = 'hyprpicker', stop reason = signal SIGSEGV: invalid address (fault address: 0x1c)
* frame #0: 0x00000008229f1858 libwayland-client.so.0`wl_map_insert_at(map=0x0000000837b7f080, flags=1, i=3, data=0x0000000000000000) at wayland-util.c:275:16
frame #1: 0x00000008229ec3f1 libwayland-client.so.0`proxy_destroy(proxy=0x0000000837b63140) at wayland-client.c:510:3
frame #2: 0x00000008229ea226 libwayland-client.so.0`wl_proxy_destroy_caller_locks(proxy=0x0000000837b63140) at wayland-client.c:530:2
frame #3: 0x00000008229ea5ce libwayland-client.so.0`wl_proxy_marshal_array_flags(proxy=0x0000000837b63140, opcode=0, interface=0x0000000000000000, version=4, flags=1, args=0x000000082072a310) at wayland-client.c:868:3
frame #4: 0x00000008229ea703 libwayland-client.so.0`wl_proxy_marshal_flags(proxy=0x0000000837b63140, opcode=0, interface=0x0000000000000000, version=4, flags=1) at wayland-client.c:791:9
frame #5: 0x0000000000211596 hyprpicker`wl_surface_destroy(wl_surface=0x0000000837b63140) at wayland-client-protocol.h:3680:2
frame #6: 0x00000000002111cd hyprpicker`CLayerSurface::~CLayerSurface(this=0x0000000837b94000) at LayerSurface.cpp:36:5
frame #7: 0x000000000020e63b hyprpicker`std::__1::default_delete<CLayerSurface>::operator()[abi:v160000](this=0x0000000837b51010, __ptr=0x0000000837b94000) const at unique_ptr.h:65:5
frame #8: 0x000000000020e5bc hyprpicker`std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>::reset[abi:v160000](this=0x0000000837b51010, __p=0x0000000000000000) at unique_ptr.h:297:7
frame #9: 0x000000000020e559 hyprpicker`std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>::~unique_ptr[abi:v160000](this=0x0000000837b51010) at unique_ptr.h:263:75
frame #10: 0x000000000020e535 hyprpicker`void std::__1::__destroy_at[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, 0>(__loc=0x0000000837b51010) at construct_at.h:66:13
frame #11: 0x000000000020e515 hyprpicker`void std::__1::destroy_at[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, 0>(__loc=0x0000000837b51010) at construct_at.h:91:5
frame #12: 0x000000000020e4f9 hyprpicker`void std::__1::allocator_traits<std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>>>::destroy[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, void, void>((null)=0x0000000837b7a068, __p=0x0000000837b51010) at allocator_traits.h:323:9
frame #13: 0x000000000020e4b8 hyprpicker`std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>>>::__base_destruct_at_end[abi:v160000](this=0x0000000837b7a058 size=1, __new_last=0x0000000837b51010) at vector:836:9
frame #14: 0x000000000020e368 hyprpicker`std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>>>::__clear[abi:v160000](this=0x0000000837b7a058 size=1) at vector:830:29
frame #15: 0x000000000020e245 hyprpicker`std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>>>::__destroy_vector::operator()[abi:v160000](this=0x000000082072a5c0) at vector:446:20
frame #16: 0x000000000020e115 hyprpicker`std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface>>>>::~vector[abi:v160000](this=0x0000000837b7a058 size=1) at vector:456:67
frame #17: 0x000000000020e0ba hyprpicker`CHyprpicker::~CHyprpicker(this=0x0000000837b7a000) at hyprpicker.hpp:15:7
frame #18: 0x000000000020e05b hyprpicker`std::__1::default_delete<CHyprpicker>::operator()[abi:v160000](this=0x0000000000219410, __ptr=0x0000000837b7a000) const at unique_ptr.h:65:5
frame #19: 0x000000000020dfdc hyprpicker`std::__1::unique_ptr<CHyprpicker, std::__1::default_delete<CHyprpicker>>::reset[abi:v160000](this=0x0000000000219410, __p=0x0000000000000000) at unique_ptr.h:297:7
frame #20: 0x000000000020d8f9 hyprpicker`std::__1::unique_ptr<CHyprpicker, std::__1::default_delete<CHyprpicker>>::~unique_ptr[abi:v160000](this=0x0000000000219410) at unique_ptr.h:263:75
frame #21: 0x00000008274a055a libc.so.7`__cxa_finalize + 362
frame #22: 0x00000008274a0ae1 libc.so.7`exit + 33
frame #23: 0x0000000000211c8b hyprpicker`CHyprpicker::finish(this=0x0000000837b7a000, code=0) at hyprpicker.cpp:56:5
frame #24: 0x000000000020d5f1 hyprpicker`Events::handleKeyboardKey(data=0x0000000837b63280, keyboard=0x0000000837b63500, serial=27052, time=64328742, key=1, state=1) at Events.cpp:268:24
frame #25: 0x0000000828e1361a libffi.so.8`ffi_call_unix64 at unix64.S:104
frame #26: 0x0000000828e128b2 libffi.so.8`ffi_call_int(cif=0x000000082072a960, fn=(hyprpicker`Events::handleKeyboardKey(void*, wl_keyboard*, unsigned int, unsigned int, unsigned int, unsigned int) at Events.cpp:266), rvalue=0x0000000000000000, avalue=0x000000082072a990, closure=0x0000000000000000) at ffi64.c:673:3
frame #27: 0x0000000828e12422 libffi.so.8`ffi_call(cif=0x000000082072a960, fn=(hyprpicker`Events::handleKeyboardKey(void*, wl_keyboard*, unsigned int, unsigned int, unsigned int, unsigned int) at Events.cpp:266), rvalue=0x0000000000000000, avalue=0x000000082072a990) at ffi64.c:710:3
frame #28: 0x00000008229ef858 libwayland-client.so.0`wl_closure_invoke(closure=0x0000000837b92b00, flags=1, target=0x0000000837b63500, opcode=3, data=0x0000000837b63280) at connection.c:1025:2
frame #29: 0x00000008229ed0df libwayland-client.so.0`dispatch_event(display=0x0000000837b7f000, queue=0x0000000837b7f0d0) at wayland-client.c:1595:3
frame #30: 0x00000008229ebf64 libwayland-client.so.0`dispatch_queue(display=0x0000000837b7f000, queue=0x0000000837b7f0d0) at wayland-client.c:1741:3
frame #31: 0x00000008229ebd2d libwayland-client.so.0`wl_display_dispatch_queue_pending(display=0x0000000837b7f000, queue=0x0000000837b7f0d0) at wayland-client.c:1983:8
frame #32: 0x00000008229eb8fe libwayland-client.so.0`wl_display_dispatch_queue(display=0x0000000837b7f000, queue=0x0000000837b7f0d0) at wayland-client.c:1959:9
frame #33: 0x00000008229ebfe0 libwayland-client.so.0`wl_display_dispatch(display=0x0000000837b7f000) at wayland-client.c:2026:9
frame #34: 0x0000000000211ac9 hyprpicker`CHyprpicker::init(this=0x0000000837b7a000) at hyprpicker.cpp:34:26
frame #35: 0x0000000000215d4a hyprpicker`main(argc=1, argv=0x000000082072ad48, envp=0x000000082072ad58) at main.cpp:65:20
frame #36: 0x000000000020a2e0 hyprpicker`_start(ap=<unavailable>, cleanup=<unavailable>) at crt1_c.c:75:7
GCC backtrace
$ export CC=gcc CXX=g++ CXXFLAGS=-stdlib=libc++
$ cmake -G Ninja -B /tmp/hyprpicker_build
$ cmake --build /tmp/hyprpicker_build
$ cmake --install /tmp/hyprpicker_build
$ hyprpicker
<press ESC to exit>
Segmentation fault
0x0000000800676858 in wl_map_insert_at (map=0x801a36080, flags=1, i=3, data=0x0) at ../src/wayland-util.c:275
275 start[i].data = data;
(gdb) bt
#0 0x0000000800676858 in wl_map_insert_at (map=0x801a36080, flags=1, i=3, data=0x0) at ../src/wayland-util.c:275
#1 0x00000008006713f1 in proxy_destroy (proxy=0x801a1a140) at ../src/wayland-client.c:510
#2 0x000000080066f226 in wl_proxy_destroy_caller_locks (proxy=0x801a1a140) at ../src/wayland-client.c:530
#3 0x000000080066f5ce in wl_proxy_marshal_array_flags (proxy=0x801a1a140, opcode=0, interface=0x0, version=4, flags=1,
args=0x7fffffffcaf0) at ../src/wayland-client.c:868
#4 0x000000080066f703 in wl_proxy_marshal_flags (proxy=0x801a1a140, opcode=0, interface=0x0, version=4, flags=1)
at ../src/wayland-client.c:791
#5 0x000000000040bc2f in wl_surface_destroy (wl_surface=0x801a1a140) at /usr/include/wayland-client-protocol.h:3680
#6 0x000000000040ba9b in CLayerSurface::~CLayerSurface (this=0x801a4b000, __in_chrg=<optimized out>)
at hyprpicker-bec451e/src/helpers/LayerSurface.cpp:36
#7 0x000000000040ae8d in std::__1::default_delete<CLayerSurface>::operator()[abi:v160000](CLayerSurface*) const (__ptr=0x801a4b000,
this=0x801a08010) at /usr/include/c++/v1/__memory/unique_ptr.h:65
#8 std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >::reset[abi:v160000](CLayerSurface*) (__p=0x0,
this=0x801a08010) at /usr/include/c++/v1/__memory/unique_ptr.h:297
#9 std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >::~unique_ptr[abi:v160000]() (this=0x801a08010,
__in_chrg=<optimized out>) at /usr/include/c++/v1/__memory/unique_ptr.h:263
#10 std::__1::__destroy_at[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, 0>(std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >*) (__loc=0x801a08010)
at /usr/include/c++/v1/__memory/construct_at.h:66
#11 std::__1::destroy_at[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, 0>(std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >*) (__loc=0x801a08010)
at /usr/include/c++/v1/__memory/construct_at.h:91
#12 std::__1::allocator_traits<std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > > >::destroy[abi:v160000]<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, void, void>(std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > >&, std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >*) (__p=0x801a08010)
at /usr/include/c++/v1/__memory/allocator_traits.h:323
#13 std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, std::__1::allocator<std::__1::unique--Type <RET> for more, q to quit, c to continue without paging--
_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > > >::__base_destruct_at_end[abi:v160000](std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >*) (__new_last=0x801a08010, this=0x801a31058)
at /usr/include/c++/v1/vector:836
#14 std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > > >::__clear[abi:v160000]() (this=0x801a31058)
at /usr/include/c++/v1/vector:830
#15 std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > > >::__destroy_vector::operator()[abi:v160000]() (this=<optimized out>)
at /usr/include/c++/v1/vector:446
#16 std::__1::vector<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> >, std::__1::allocator<std::__1::unique_ptr<CLayerSurface, std::__1::default_delete<CLayerSurface> > > >::~vector[abi:v160000]() (this=0x801a31058, __in_chrg=<optimized out>)
at /usr/include/c++/v1/vector:456
#17 CHyprpicker::~CHyprpicker (this=0x801a31000, __in_chrg=<optimized out>)
at hyprpicker-bec451e/src/helpers/../hyprpicker.hpp:15
#18 0x000000000040aa7a in std::__1::default_delete<CHyprpicker>::operator()[abi:v160000](CHyprpicker*) const (__ptr=0x801a31000,
this=0x619c08 <g_pHyprpicker>) at /usr/include/c++/v1/__memory/unique_ptr.h:65
#19 std::__1::unique_ptr<CHyprpicker, std::__1::default_delete<CHyprpicker> >::reset[abi:v160000](CHyprpicker*) (__p=0x0,
this=0x619c08 <g_pHyprpicker>) at /usr/include/c++/v1/__memory/unique_ptr.h:297
#20 std::__1::unique_ptr<CHyprpicker, std::__1::default_delete<CHyprpicker> >::~unique_ptr[abi:v160000]() (
this=0x619c08 <g_pHyprpicker>, __in_chrg=<optimized out>)
at /usr/include/c++/v1/__memory/unique_ptr.h:263
#21 0x0000000800ce555a in __cxa_finalize () from /lib/libc.so.7
#22 0x0000000800ce5ae1 in exit () from /lib/libc.so.7
#23 0x000000000040ee86 in CHyprpicker::finish (this=0x801a31000, code=0)
at hyprpicker-bec451e/src/hyprpicker.cpp:56
#24 0x000000000040a275 in Events::handleKeyboardKey (data=0x801a1a280, keyboard=0x801a1a500, serial=27878, time=64519108, key=1,
state=1) at hyprpicker-bec451e/src/events/Events.cpp:268
#25 0x0000000800faf61a in ffi_call_unix64 () at ../src/x86/unix64.S:104
#26 0x0000000800fae8b2 in ffi_call_int (cif=0x7fffffffd550,
fn=0x40a22b <Events::handleKeyboardKey(void*, wl_keyboard*, unsigned int, unsigned int, unsigned int, unsigned int)>, rvalue=0x0,
avalue=0x7fffffffd580, closure=0x0) at ../src/x86/ffi64.c:673
#27 0x0000000800fae422 in ffi_call (cif=0x7fffffffd550,
fn=0x40a22b <Events::handleKeyboardKey(void*, wl_keyboard*, unsigned int, unsigned int, unsigned int, unsigned int)>, rvalue=0x0,
avalue=0x7fffffffd580) at ../src/x86/ffi64.c:710
#28 0x0000000800674858 in wl_closure_invoke (closure=0x801a49b00, flags=1, target=0x801a1a500, opcode=3, data=0x801a1a280)
at ../src/connection.c:1025
#29 0x00000008006720df in dispatch_event (display=0x801a36000, queue=0x801a360d0) at ../src/wayland-client.c:1595
#30 0x0000000800670f64 in dispatch_queue (display=0x801a36000, queue=0x801a360d0) at ../src/wayland-client.c:1741
#31 0x0000000800670d2d in wl_display_dispatch_queue_pending (display=0x801a36000, queue=0x801a360d0) at ../src/wayland-client.c:1983
#32 0x00000008006708fe in wl_display_dispatch_queue (display=0x801a36000, queue=0x801a360d0) at ../src/wayland-client.c:1959
#33 0x0000000800670fe0 in wl_display_dispatch (display=0x801a36000) at ../src/wayland-client.c:2026
#34 0x000000000040eb55 in CHyprpicker::init (this=0x801a31000)
at hyprpicker-bec451e/src/hyprpicker.cpp:34
#35 0x0000000000415636 in main (argc=1, argv=0x7fffffffea10, envp=0x7fffffffea20)
at hyprpicker-bec451e/src/main.cpp:65
from hyprpicker.
my bad. e4c2672
from hyprpicker.
I confirm, e4c2672 snapshot works fine.
from hyprpicker.
Related Issues (20)
- frozen image is flipped in portrait mode HOT 2
- error: 'uint' has not been declared HOT 3
- 'hyprpicker' terminated by signal SIGSEGV (Address boundary error) HOT 15
- grimblast --freeze bus error
- Color doesn't get picked HOT 2
- Cancel with actual Escape key
- not removing temporary files in /run/user/1000
- Memory leak? HOT 1
- Sample an area for color picking
- Add pixel grid
- segfault: Invalid stride (9023) HOT 1
- hyprpicker command returns: segmentation fault (core dumped) HOT 7
- [destroyed object]: error 1: Invalid stride(10240) HOT 1
- Segmentation fault (core dumped) HOT 12
- Fails to Build on NixOS
- I want to adapt it into a library to obtain color information
- Add option for lowercase hex
- Add color preview HOT 2
- Magnifying lens size HOT 2
- Focus windows before picking
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hyprpicker.