Creating URL links

This is a discussion on Creating URL links within the C Programming forums, part of the General Programming Boards category; I have a text file with a bunch of links in it. I want to be able to create URL ...

Creating URL links

I have a text file with a bunch of links in it. I want to be able to create URL links for each one so I could put them in my bookmarks. The name for each link would be the link, with the special chars taken out. This is what I got.

Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah

You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie

Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah

You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie

Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah

You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie

Instead of arbitrarily choosing buffer sizes, why not use FILENAME_MAX? (FILENAME_MAX is a macro "which expands to an integer constant expression that is the size needed for an array of char large enough to hold the longest file name string that the implementation guarantees can be opened".) Perhaps something like this.