syvaidya / openstego

OpenStego is a steganography application that provides two functionalities: a) Data Hiding: It can hide any data within an image file. b) Watermarking: Watermarking image files with an invisible signature. It can be used to detect unauthorized file copying.
https://www.openstego.com
GNU General Public License v2.0
1.13k stars 206 forks source link

java.lang.NullPointerException #31

Closed RossComputerGuy closed 5 years ago

RossComputerGuy commented 5 years ago
java.lang.NullPointerException
    at com.openstego.desktop.util.UserPreferences.init(UserPreferences.java:57)
    at com.openstego.desktop.OpenStego.main(OpenStego.java:429)

I just installed it

MrCode97 commented 5 years ago

Executing from openstego (not within the /lib folder) worked fine for me: java -jar lib/openstego.jar or java -jar <absolute path>/openstego/lib/openstego.jar

RossComputerGuy commented 5 years ago

I'm using the AUR package.

syvaidya commented 5 years ago

@SpaceboyRoss01 not sure what is AUR package, but looks like that the package is incorrectly built. Can you check if openstego.jar file is there, and if so extract the contents using any zip utility and check if following file exists: com/openstego/desktop/resource/openstego.ini

RossComputerGuy commented 5 years ago

https://aur.archlinux.org/packages/openstego/ this is what I'm using because I'm using Arch and I don't know where the jar is located

RossComputerGuy commented 5 years ago

@MrCode97 I don't know where the lib directory for openstego is.

RossComputerGuy commented 5 years ago

I found out openstego is located at /usr/share/java/openstego/openstego.jar but running it still causes a NullPointerException.02.12.2018, 20:39, "SpaceboyRoss01" notifications@github.com:@MrCode97 I don't know where the lib directory for openstego is.

—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or mute the thread.

syvaidya commented 5 years ago

I saw that in that package the openstego.sh is having following line:

java -jar "/usr/share/java/openstego/openstego.jar" "$@"

It seems to be okay. Did you try running openstego using "openstego.sh" script?

RossComputerGuy commented 5 years ago

Yes--Sent from Yandex.Mail for mobile08.12.2018, 02:27, "Samir Vaidya" notifications@github.com:I saw that in that package the openstego.sh is having following line: java -jar "/usr/share/java/openstego/openstego.jar" "$@" It seems to be okay. Did you try running openstego using "openstego.sh" script?

—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or mute the thread.

syvaidya commented 5 years ago

Can you try downloading zip version directly from github releases, and try that instead of using ArchLinux package?

RossComputerGuy commented 5 years ago

it does the same thing.

syvaidya commented 5 years ago

Thanks, I am able to reproduce it. The issue happens only first time you launch OpenStego. It fails with NPE, but it still creates "openstego.ini" file in the user's home folder, and next launch onwards it works fine. I'll fix this with next release.

syvaidya commented 5 years ago

Fixed in master branch. Will be part of next release.