danikula / danikula/AndroidVideoCache

Attempt to write to field 'com.android.okio.Segment com.android.okio.Segment.next' on a null object reference

Open
#270 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
5.5k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

Attempt to write to field 'com.android.okio.Segment com.android.okio.Segment.next' on a null object reference

java.lang.RuntimeException:Wait... but why? WTF!? Really shouldn't happen any more after fixing https://github.com/danikula/AndroidVideoCache/issues/43. If you read it on your device log, please, notify me danikula@gmail.com or create issue here https://github.com/danikula/AndroidVideoCache/issues.
--
2 e.d.a.h.close(SourceFile:4)
3 ......
4 Caused by:
5 java.lang.NullPointerException:Attempt to write to field 'com.android.okio.Segment com.android.okio.Segment.next' on a null object reference
6 com.android.okio.Segment.pop(Segment.java:54)
7 com.android.okio.OkBuffer.write(OkBuffer.java:592)
8 com.android.okio.OkBuffer.read(OkBuffer.java:610)
9 com.android.okio.RealBufferedSource.read(RealBufferedSource.java:53)
10 com.android.okhttp.internal.http.HttpConnection$FixedLengthSource.read(HttpConnection.java:442)
11 com.android.okhttp.internal.Util.skipAll(Util.java:227)
12 com.android.okhttp.internal.http.HttpConnection.discard(HttpConnection.java:212)
13 com.android.okhttp.internal.http.HttpConnection$FixedLengthSource.close(HttpConnection.java:464)
14 com.android.okhttp.internal.Util.closeQuietly(Util.java:97)
15 com.android.okhttp.internal.http.HttpEngine.close(HttpEngine.java:433)
16 com.android.okhttp.internal.http.HttpURLConnectionImpl.disconnect(HttpURLConnectionImpl.java:113)
17 com.android.okhttp.internal.http.DelegatingHttpsURLConnection.disconnect(DelegatingHttpsURLConnection.java:93)
18 com.android.okhttp.internal.http.HttpsURLConnectionImpl.disconnect(HttpsURLConnectionImpl.java:25)
19 e.d.a.h.close(SourceFile:2)
20 e.d.a.m.c(SourceFile:1)
21 e.d.a.m.f(SourceFile:18)
22 e.d.a.m.a(SourceFile:1)
23 e.d.a.m$b.run(SourceFile:1)
24 java.lang.Thread.run(Thread.java:818)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the reported call chain at com.android.okio.Segment.pop, then trace the reads and disconnect path through OkBuffer.java, RealBufferedSource.java, and HttpConnection.java. Reproduce the null-reference failure if possible and establish a verified regression test or documented resolution; the report provides no project test or reproduction steps.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
15/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.