Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6806945
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T19:46:20+00:00 2026-05-26T19:46:20+00:00

I am specifically asking about this paragraph in the Android documentation: If the object

  • 0

I am specifically asking about this paragraph in the Android documentation:

If the object you pass is for some reason tied to the
Activity/Context, you will leak all the views and resources of the
activity.

You can find this paragraph on the page about Faster Screen Orientation changes.

I assume they mean objects that keep a reference to the Activity/Context. In my Activity, I am returning a HashMap in onRetainNonConfigurationInstance, so I assume I am fine, since none of the objects in that HashMap contain references to the Activity/Context. But I want to make sure; I am still learning about how leaks happen in Android.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T19:46:20+00:00Added an answer on May 26, 2026 at 7:46 pm

    Patrick Dubroy has shown a video tutorial doing showing something similar. Then he proceeds to debug that leak. I guess you can follow the same procedure to confirm if your code is really leaky or not.

    You are right, if the objects keep a reference to the Activity or Context, it won’t allow the GC to collect those unused Activities, thus create a huge leaks.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am specifically asking about javascript on a mobile webpage, not an objective-c application.
More specifically, what do I need to know about doing this in Visual Studio
I'm asking this specifically regarding Visual Studio 2008 and also the upcoming Visual Studio
Specifically this is regarding when using a client session cookie to identify a session
Specifically, I have a model that has a field like this pub_date = models.DateField(date
This is pretty much Python, but asking from a Django user. Suppose this is
This is a question that arose mostly of pure curiosity (and killing some time).
I asked this question in a more general design context before. Now, I'd like
Just for a short bit of background, the reason I'm tracking this particular subversion
I am a working on an Android app and am a bit confused about

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.