From: "J." <mailing-lists@xs4all.nl>
To: linux-c-programming@vger.kernel.org
Subject: returning strings until no strings are left ?
Date: Mon, 16 Dec 2002 21:46:02 +0100 (CET) [thread overview]
Message-ID: <Pine.LNX.4.21.0212162133410.18647-100000@hestia> (raw)
In-Reply-To: <Pine.LNX.4.44.0212161043290.4841-100000@ns.isi.ulatina.ac.cr>
Hello,
I am new to c programming but not new to programming in general . The
``minor'' problem I keep running into at this moment:
I know how to return ONE string from a function. But what if I want to
keep returning strings from a function until there are no strings left to
return ? What should the function than return ? Because the function
should always return something in the end and of course the caller has to
know that the function is done or has nothing more to return .
for example fgets returns NULL when it's done, but if I try to return a
NULL at the end of my function while I claimed it as an char *... hmmzzz,
status epilepticus...
Thank you in advance...
J.
prev parent reply other threads:[~2002-12-16 20:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-15 12:38 help on subscribing Nicholas Ho
2002-12-16 16:44 ` Fabio Miranda Hamburger
2002-01-18 13:21 ` Nicholas Ho
2003-08-26 15:39 ` Port 786 (Concert??) Darío Mariani
2003-08-26 15:49 ` Darío Mariani
2003-08-26 15:53 ` Tony Clarke
2003-08-26 16:06 ` Paolo Dovera
2002-12-16 20:46 ` J. [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.21.0212162133410.18647-100000@hestia \
--to=mailing-lists@xs4all.nl \
--cc=linux-c-programming@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).