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

Exception #46

Closed
UXDart opened this issue Jul 23, 2013 · 6 comments
Closed

Exception #46

UXDart opened this issue Jul 23, 2013 · 6 comments

Comments

@UXDart
Copy link

UXDart commented Jul 23, 2013

Hi again :)
I'm having this exception:

I'm uploading a file, it finish to upload and the file is uploaded ok. but the callback comes with an exception as a parameter.

any idea?
Thanks!

W/System.err( 2128): java.lang.NullPointerException
W/System.err( 2128): at ajo.onDataAvailable(SourceFile:239)
W/System.err( 2128): at com.koushikdutta.async.DataEmitterReader.a(SourceFile:23)
W/System.err( 2128): at com.koushikdutta.async.DataEmitterReader.onDataAvailable(SourceFile:38)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at com.koushikdutta.async.FilteredDataEmitter.onDataAvailable(SourceFile:50)
W/System.err( 2128): at com.koushikdutta.async.http.filter.ContentLengthFilter.onDataAvailable(SourceFile:31)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at aik.onDataAvailable(SourceFile:113)
W/System.err( 2128): at com.koushikdutta.async.BufferedDataEmitter.onDataAvailable(SourceFile:33)
W/System.err( 2128): at com.koushikdutta.async.BufferedDataEmitter.onDataAvailable(SourceFile:61)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at com.koushikdutta.async.AsyncNetworkSocket.b(SourceFile:170)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.c(SourceFile:805)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.b(SourceFile:664)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.a(SourceFile:34)
W/System.err( 2128): at air.run(SourceFile:612)
W/System.err( 2128): java.lang.NullPointerException
W/System.err( 2128): at com.koushikdutta.async.DataEmitterReader.a(SourceFile:23)
W/System.err( 2128): at com.koushikdutta.async.DataEmitterReader.onDataAvailable(SourceFile:38)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at com.koushikdutta.async.FilteredDataEmitter.onDataAvailable(SourceFile:50)
W/System.err( 2128): at com.koushikdutta.async.http.filter.ContentLengthFilter.onDataAvailable(SourceFile:31)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at aik.onDataAvailable(SourceFile:113)
W/System.err( 2128): at com.koushikdutta.async.BufferedDataEmitter.onDataAvailable(SourceFile:33)
W/System.err( 2128): at com.koushikdutta.async.BufferedDataEmitter.onDataAvailable(SourceFile:61)
W/System.err( 2128): at com.koushikdutta.async.Util.emitAllData(SourceFile:20)
W/System.err( 2128): at com.koushikdutta.async.AsyncNetworkSocket.b(SourceFile:170)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.c(SourceFile:805)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.b(SourceFile:664)
W/System.err( 2128): at com.koushikdutta.async.AsyncServer.a(SourceFile:34)

@koush
Copy link
Owner

koush commented Jul 24, 2013

Can you let me know which variable in DataEmitterReader is causing the null reference?

@UXDart
Copy link
Author

UXDart commented Jul 24, 2013

that's the problem, I'm not sure. it seems that pendingRead was null.
the crash happened only two times, I can't reproduce it all the times.

Thanks

@UXDart
Copy link
Author

UXDart commented Jul 26, 2013

when it works, pendingRead contains a "com.koushikdutta.async.http.filter.ContentLengthFilter"
and looking into file HttpUtil.java method getBodyDecoder()
there are a lot of if() {}, but it is possible that none of them are called. so emitter is null. what do you think? TIA

Edit: oh... it seems that before calling getBodyDecoder there is check for emitter==null... I'm lost, but for some reason it happens :(

@UXDart
Copy link
Author

UXDart commented Jul 26, 2013

I made a search for "void onDataAvailable" to see which one has a line number 239.
and the only one is PushParser. so it needs to be that method line 239:

                method.invoke(callback, args);

it seems method is null??

@koush
Copy link
Owner

koush commented Jul 26, 2013

Oh, please update to the latest. Should be fixed with:

koush/ion#34

@UXDart
Copy link
Author

UXDart commented Jul 26, 2013

Thanks!

@UXDart UXDart closed this as completed Jul 26, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants