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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T19:28:22+00:00 2026-06-02T19:28:22+00:00

I am trying to send an email from a C++ program using imap library.

  • 0

I am trying to send an email from a C++ program using imap library. I have a Google Apps and a Gmail account to which I am sending the email.

Whenever the program fails to send an email I am logging the errors to a file.

I set my program to run in loop to send the emails. Sometimes, I don’t get the emails and when I checked the log file I found out these errors being logged every time sending the email fails.

Here is the part of the log file:

[2012-04-23 11:04:34]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (2753 >= 1024)
[2012-04-23 11:04:34]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (2753 >= 1024)
[2012-04-23 11:05:36]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1692 >= 1024)
[2012-04-23 11:05:36]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1692 >= 1024)
[2012-04-23 11:07:52]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1605 >= 1024)
[2012-04-23 11:07:52]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1605 >= 1024)
[2012-04-23 11:08:02]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1566 >= 1024)
[2012-04-23 11:08:02]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1566 >= 1024)
[2012-04-23 11:08:09]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1067 >= 1024)
[2012-04-23 11:08:09]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1067 >= 1024)
[2012-04-23 11:08:19]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1648 >= 1024)
[2012-04-23 11:08:19]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1648 >= 1024)
[2012-04-23 11:08:20]   ErrCode:1 ErrMsg:Unable to create selectable TCP socket (1130 >= 1024)
[2012-04-23 11:08:20]   ErrCode:2 ErrMsg:Unable to create selectable TCP socket (1130 >= 1024)

Is it related to imap server port? If so, which port should it be set to? 993 always??
How to troubleshoot this error?

Here are my setting:

Name: Ashwin
my email: blahblah@wyswtf.com
reply-to-email: blahblah@wyswtf.com

SMTP server information:

Host: smtp.gmail.com
Encryption: SSL
Port: 465

The program runs as root user and the library that I am using is from http://panda.com/imap/

  • 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-06-02T19:28:23+00:00Added an answer on June 2, 2026 at 7:28 pm

    The library uses some ancient I/O multiplexing code and as a result it can only handle 1,024 connections at a time. Either use a different library or rate-limit your requests to the library.

    Update: I was going to research this for you and, if necessary, fix the code to work around this or figure out changes to how you build the code. But it seems the library is not publicly available. Sorry, we can’t fix closed source code for you.

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

Sidebar

Related Questions

I am trying to send an email via GMail from ASP.Net using the code
I am trying to send an email from PHP using PHPmailer() . I have
I am trying to send an email from a Ruby program. The smtp server
I am trying to send email using Exchange 2007 from a console app using
I am trying to send an email via Outlook from within a VB6 program.
Simply put, I'm trying to send an email from a Powershell script which lists
I am trying to send an smtp email through gmail's smtp server using the
I'm trying to automatically retrieve some email from my GMail account for further parsing,
I'm trying to send an email using JavaMail API. I have jdk 1.5 installed
i am trying to send email from php i have one php file with

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.