joschi70 / AndroidPirateBox

Android version of PirateBox
MIT License
73 stars 16 forks source link

Using the new PirateBoxFileHandler breaks everything for me. #8

Closed WhatIsThisImNotGoodWithComputers closed 10 years ago

WhatIsThisImNotGoodWithComputers commented 10 years ago

Not sure if issue or work in progress. Using latest source, updating line 141 from content.zip/conf/handler.xml

<param name="filehandler.class" value="org.paw.handler.PirateBoxFileHandler" />

to

<param name="filehandler.class" value="de.fun2code.android.piratebox.handler.PirateBoxFileHandler" />

will result in every page giving me a file not found. All urls are still hijacked and pointing to pirate.box, but file not found. I went back to 0.4.8 which is working for me.

joschi70 commented 10 years ago

Just checked but unfortunately I could not reproduce the error. Could you please check if the class de.fun2code.android.piratebox.handler.PirateBoxFileHandler is available.

To check if it is really the new class causing the error you could also use the old class valueorg.paw.handler.PirateBoxFileHandler. Maybe the new class is not the reason for the error.

What you also could check is if the handler initialization works or if there are any errors. For that you could enable logging. The file conf/server.xml contains the line <log>0</log>. If you change this to <log>5</log> and restart the server, a log file called logs/server.log should be created. Maybe there are errors in there, you can also send me the log via email.

WhatIsThisImNotGoodWithComputers commented 10 years ago

The file de.fun2code.android.piratebox.handler.PirateBoxFileHandler is available. As soon as I update the configuration to use this one instead of org.paw.handler.PirateBoxFileHandler I get the not found error for every page. Which struck me as strange as the first one extends the second one. The second one, org.paw.handler.PirateBoxFileHandler,works fine for me. I will report back later, hopefully tonight, with logging info.

edit; I also thought the fault could be somewhere among my own changes, but I specifically narrowed it down to this line.

WhatIsThisImNotGoodWithComputers commented 10 years ago

I'm sorry, made a mistake, does appear it was one of my changes. Everything seems to work as supposed.