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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T00:31:25+00:00 2026-05-19T00:31:25+00:00

In the app I’m currently working, I use Mailcore ( http://www.mronge.com/m/MailCore/API/ ) to handle

  • 0

In the app I’m currently working, I use Mailcore (http://www.mronge.com/m/MailCore/API/) to handle mail server operations. I’m trying to send a message over an SMTP connection in the background. The problem is, Leaks is telling me that I get a decent amount of memory leaks every time a message sends. I’m trying to figure if this is my fault or Mailcore’s fault. Here’s the code:

From my view controller:

-(void) send_rfq {

    CTCoreMessage *repMsg = [[[CTCoreMessage alloc] init] autorelease];
    NSDate *now = [NSDate date];

    NSString* msgString = [NSString stringWithFormat:@"Date#%@\nRFQ#%@\nSalesRep#%@",[now description], [rfq_entry get_uid],[rfq_entry get_repid]];
    [repMsg setBody:msgString];
    [repMsg setSubject:@"RFQ Assign"];

    [myAppDelegate performSelectorInBackground:@selector(send_msg:) withObject:repMsg];

    [self.navigationController popViewControllerAnimated:YES]; 
}

From my app delegate:

-(BOOL) send_bg:(CTCoreMessage*) msg {
    BOOL success = TRUE;
    @try {
        [CTSMTPConnection sendMessage:msg server:smtp_server username:smtp_uname password:smtp_pass port:smtp_port useTLS:smtp_tls useAuth:smtp_auth];
    }
    @catch (NSException * e) {
        //Msg failed to send;
        success = FALSE;
    }
    return success;
}

-(void) send_msg:(CTCoreMessage*) msg {
    NSAutoreleasePool *pool = [ [NSAutoreleasePool alloc] init];
    [msg setTo:[NSSet setWithObject:[CTCoreAddress addressWithName:@"testaccount" email:rfq_dest]]];
    [msg setFrom:[NSSet setWithObject:[CTCoreAddress addressWithName:@"RFQapp" email:rfq_src]]];
    if(![self send_bg:msg]) {
        UIAlertView * empty_alert = [[UIAlertView alloc] initWithTitle:@"Error" message:@"Could not send." delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil, nil];
        [empty_alert show];
        [empty_alert autorelease];
    }
    [pool release];
}
  • 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-19T00:31:25+00:00Added an answer on May 19, 2026 at 12:31 am

    There are no leaks in the code you’ve posted. Either the leak is a false positive or it’s elsewhere in your code. Have you tried profiling your app with Instruments? Have you tried using Build and Analyze to do static analysis of your code?

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

Sidebar

Related Questions

App Engine only allows you to use these formats for XMPP addresses: app-id@appspot.com anything@app-id.appspotchat.com
My app must report its job load via HTTP API. The play status command
The app I'm working on is relatively simple but it is throwing memory warnings.
My app allows users to have custom subdomains, as in user1.domain.com. I am integrating
The app Im working on uses gps and sometimes in the onResume when the
I want use html5's new tag to play a wav file (currently only supported
My app needs to be able to disconnect from a server and connect to
my app was working perfectly fine, until I cleaned the targets and deleted the
app.js: app.use(express.compiler({ src: __dirname + '/public', enable: ['less']})); app.use(express.static(__dirname + '/public')); In my jade
I am using Paperclip to handle profile photo uploads in my app. They upload

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.