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 6866393
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T03:10:41+00:00 2026-05-27T03:10:41+00:00

I got a UIWebView in my project with DSBezelActivityView but it seems to have

  • 0

I got a UIWebView in my project with DSBezelActivityView but it seems to have a memory leak. I use the DSBezelActivityView for when the page is loading. It works as it should beside the memory leak. How do I solve this memory leak?

I used this code:
http://www.dejal.com/developer/dsactivityview

This is what analyzer says:
Object leaked: allocated object is not referenced later in this execution path and has a retain count of +1
Method returns an Objective-C object with a +1 retain count

- (void)viewDidLoad
{

NSString *urlAddress = [NSString stringWithFormat:@"http://www.google.be"];

//Create a URL object.
NSURL *url = [NSURL URLWithString:urlAddress];

//URL Requst Object
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
webView.delegate = self;

//Load the request in the UIWebView.
[webView loadRequest:requestObj];
[super viewDidLoad];

}
- (void)webViewDidStartLoad:(UIWebView *)webView {
[DSBezelActivityView newActivityViewForView:aiv withLabel:@"Laden..." width:90];
NSLog(@"werkt dit");

}
- (void)webViewDidFinishLoad:(UIWebView *)webView {
[DSBezelActivityView removeView];

}  
  • 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-27T03:10:41+00:00Added an answer on May 27, 2026 at 3:10 am

    Seems like you’re leaking the object returned by newActivityViewForView:withLabel:width.

    According to Apple’s documentation:

    You own any object you create

    You create an object using a method whose name begins with “alloc”, “new”, “copy”, or “mutableCopy” (for
    example, alloc, newObject, or mutableCopy).

    So you need to release the object at a proper moment, I think it is the webViewDidFinishLoad:. Your code should be something like these:

    - (void)webViewDidStartLoad:(UIWebView *)webView {
        DSBezelActivityView *bezelActivityView = [DSBezelActivityView newActivityViewForView:aiv withLabel:@"Laden..." width:90];
    }
    
    - (void)webViewDidFinishLoad:(UIWebView *)webView {
        [DSBezelActivityView removeView];
        [bezelActivityView release];
        bezelActivityView = nil;
    } 
    

    I don’t this DSBezelActivityView class so my answer is based on the Cocoa Memory Management Conventions. Keep in mind that could have created a method starting with new that does not follow the convention.

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

Sidebar

Related Questions

There appear to be several suggestions, but nothing seems to work: https://stackoverflow.com/search?q=UIWebview+load+local+css+remote+website&submit=search What I
In the iPad project I'm working on I've got a UIWebView inside of the
Got a window.history.go(1) to stop the user hitting the back button, but was wondering
I have a game in HTML5 I wish to enclose inside a UIWebview. I
Got a Grails 2 app and executing run-app works fine, run-war fails: 2011-12-24 12:43:40,996
I got a problem with UIWebView. I want to render my own html code
I'm developing an app that use a lot of images, I'm using the UIWebView
Got a issue with Facebook Graph API. I want to read page notifications via
I got my uiwebview working and displaying the specified url. the only problem is
I have a problem with my application that is using uiwebview to load the

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.