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

  • Home
  • SEARCH
  • 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 6650201
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T00:51:53+00:00 2026-05-26T00:51:53+00:00

I am trying to connect from an iphone app to a java server but

  • 0

I am trying to connect from an iphone app to a java server but i got stuck pretty quickly as the documentation for NSStream does not seem to match my results.

Documentation
states that after calling the function

CFReadStreamRef readStream;
CFWriteStreamRef writeStream;

CFStreamCreatePairWithSocketToHost(NULL, (CFStringRef)[website host], 80, &readStream, &writeStream); 

Either readStream or writeStream will be NULL if connection failed. But they are never NULL even if i disconnect from internet.

So what i am wondering is what i could be doing wrong or if there is a better way to do this.

thanks!

  • 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-26T00:51:54+00:00Added an answer on May 26, 2026 at 12:51 am

    Which documentation are you reading? The CFStream documentation makes no mention of returning NULL read and write streams. In fact, it states that the connection is not actually attempted until you try to open one of the returned streams.

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

Sidebar

Related Questions

I am trying to connect to a standalone desktop tcp server(java) from tcp client
I am trying to connect to SQL Server 2008 server from Java here is
HI Guys, I have following problem. I'm trying to connect from my Iphone app
I'm trying to connect from a Windows XP system to an SVN server but
I'm trying to connect to a vnc server from iPhone using NoVNC. I have
I'm trying to capture packets from my iPhone app. It does not use HTTP
I am trying to connect to a remote mysql database from an iPhone. I
I'm trying to connect from one server to another using FTP. By using command
I am trying to connect SQL Server from a Windows service. Now my Windows
I'm trying to connect and fetching source from a SSH server with using PuTTY,

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.