Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
halo
rockchip_frameworks_opt_timezonepicker
Commits
1db8933b
Commit
1db8933b
authored
12 years ago
by
Michael Chan
Browse files
Options
Download
Email Patches
Plain Diff
Fixed infinite loop when setting a time zone
Bug:8608487 Change-Id: I335b384ba3e20ea79949f1b8dd17972ff8bc3a0b
parent
46589e24
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
src/com/android/timezonepicker/TimeZoneResultAdapter.java
src/com/android/timezonepicker/TimeZoneResultAdapter.java
+7
-1
No files found.
src/com/android/timezonepicker/TimeZoneResultAdapter.java
View file @
1db8933b
...
...
@@ -32,6 +32,7 @@ import com.android.timezonepicker.TimeZoneFilterTypeAdapter.OnSetFilterListener;
import
com.android.timezonepicker.TimeZonePickerView.OnTimeZoneSetListener
;
import
java.util.ArrayList
;
import
java.util.Iterator
;
import
java.util.LinkedHashSet
;
public
class
TimeZoneResultAdapter
extends
BaseAdapter
implements
OnItemClickListener
,
...
...
@@ -192,8 +193,13 @@ public class TimeZoneResultAdapter extends BaseAdapter implements OnItemClickLis
}
}
Iterator
<
String
>
it
=
recents
.
iterator
();
while
(
recents
.
size
()
>=
MAX_RECENT_TIMEZONES
)
{
recents
.
remove
(
0
);
if
(!
it
.
hasNext
())
{
break
;
}
it
.
next
();
it
.
remove
();
}
recents
.
add
(
id
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment