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

thread 'main' panicked at index out of bounds: the len is 1 but the index is 1 after deleting profile #229

Closed
penguinencounter opened this issue Nov 11, 2022 · 1 comment
Labels
bug Something doesn't work as expected priority I'm working on it, or will be soon

Comments

@penguinencounter
Copy link

penguinencounter commented Nov 11, 2022

Description

What is the bug?
After deleting a profile (when you have more than one) every subsequent command that modifies the profile will cause ferium to crash:

> ferium profile configure
thread 'main' panicked at 'index out of bounds: the len is 1 but the index is 1', src\main.rs:400:17
stack backtrace:
   0:     0x7ff627b456de - <unknown>
   1:     0x7ff6278db0ba - <unknown>
   2:     0x7ff627b33ed9 - <unknown>
   3:     0x7ff627b46e5b - <unknown>
   4:     0x7ff627b47a65 - <unknown>
   5:     0x7ff627b47633 - <unknown>
   6:     0x7ff627b47599 - <unknown>
   7:     0x7ff627b47554 - <unknown>
   8:     0x7ff627be0e05 - <unknown>
   9:     0x7ff627be0e87 - <unknown>
  10:     0x7ff6278283d7 - <unknown>
  11:     0x7ff6277f6d12 - <unknown>
  12:     0x7ff6277e8b6d - <unknown>
  13:     0x7ff6276a6d46 - <unknown>
  14:     0x7ff627846875 - <unknown>
  15:     0x7ff627bd926c - <unknown>
  16:     0x7ffe188574b4 - BaseThreadInitThunk
  17:     0x7ffe19c426a1 - RtlUserThreadStart

To Reproduce

  1. create two profiles
  2. switch to the second one
  3. delete the first
  4. ferium profile configure

Software version

  • OS: Windows 10
  • Ferium Version: 4.2.0
@penguinencounter penguinencounter added the bug Something doesn't work as expected label Nov 11, 2022
@theRookieCoder
Copy link
Collaborator

theRookieCoder commented Nov 11, 2022

Seems to be a simple bug where I didn't account for zero indexing.

@theRookieCoder theRookieCoder added the priority I'm working on it, or will be soon label Nov 13, 2022
@theRookieCoder theRookieCoder changed the title thread 'main' panicked at 'index out of bounds: the len is 1 but the index is 1', src\main.rs:400:17 after deleting profile thread 'main' panicked at index out of bounds: the len is 1 but the index is 1 after deleting profile Nov 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something doesn't work as expected priority I'm working on it, or will be soon
Development

No branches or pull requests

2 participants