Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assertion '__n < this->size()' failed, when browsing in "Choose folder" dialog : #4442

Open
fenugrec opened this issue May 9, 2022 · 5 comments

Comments

@fenugrec
Copy link

fenugrec commented May 9, 2022

Description

When browsing folders and clicking "Up one level" a few times then selecting a folder, opentoonz crashed .

Steps to Reproduce

  1. Start Opentoonz
  2. In the "Create new scene" area, click button with three dots to change Save In:location
  3. Press "Up one level" a few times
  4. In the list on the right, double-click any folder
  5. crash

Expected Behavior

Not crash : )

Screenshots, Video & Crash Logs

Build is the one from the Arch linux repos.

Starting from the console, I get the following output after the crash:

/usr/include/c++/11.2.0/bits/stl_vector.h:1045: std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp = FileBrowser::Item; _Alloc = std::allocator<FileBrowser::Item>; std::vector<_Tp, _Alloc>::reference = FileBrowser::Item&; std::vector<_Tp, _Alloc>::size_type = long unsigned int]: Assertion '__n < this->size()' failed.
Aborted (core dumped)

OpenToonz Version

1.6

OpenToonz Version Information

Build date May 4, 2022

Operating System

Linux

GPU

AMD

Graphics Tablet

No response

@fenugrec fenugrec added the bug label May 9, 2022
@TomatDividedBy0
Copy link

TomatDividedBy0 commented Jun 9, 2022

Can confirm, have run into the exact same problem on Ubuntu 21.04.

@flurick
Copy link
Contributor

flurick commented Dec 2, 2022

@fenugrec @TomatDividedBy0 looked like theres been some change to the startup window, can you still reproduce this issue?

@fenugrec
Copy link
Author

fenugrec commented Dec 2, 2022

@flurick , just tried 2f124ee , same issue.

#0  0x00007f12aa8a164c in  () at /usr/lib/libc.so.6
#1  0x00007f12aa851958 in raise () at /usr/lib/libc.so.6
#2  0x00007f12aa83b53d in abort () at /usr/lib/libc.so.6
#3  0x00007f12b00d2112 in std::__glibcxx_assert_fail(char const*, int, char const*, char const*) (file=<optimized out>, line=<optimized out>, function=<optimized out>, condition=<optimized out>)
    at /usr/src/debug/gcc/libstdc++-v3/src/c++11/debug.cc:60
#4  0x000055e151852a40 in FileBrowser::onSelectedItems(std::set<int, std::less<int>, std::allocator<int> > const&) ()
#5  0x00007f12accbdc00 in  () at /usr/lib/libQt5Core.so.5
#6  0x000055e151aa270e in DvItemViewerPanel::mousePressEvent(QMouseEvent*) ()
#7  0x00007f12ad9af45b in QWidget::event(QEvent*) () at /usr/lib/libQt5Widgets.so.5

@RodneyBaker RodneyBaker mentioned this issue Apr 2, 2023
6 tasks
@flydiscohuebr
Copy link

Same problem using flatpak version flathub/io.github.OpenToonz#22

@hfiguiere
Copy link

Accessing any element in an empty container is UB.

Flatpak build with assertions on, so libstdc++ do catch it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants