Secure, Efficient and Easy C programming
cras writes "Feeling a bit of masochist today.. First in the morning I wrote Secure, Efficient and Easy C Programming Mini-HOWTO. And since I already spent a few hours with it, I figured I might just as well see what Slashdot people would think about it."
Pick any two.
"First in the morning I wrote Secure, Efficient and Easy C Programming Mini-HOWTO..."
Damn. What are your plans for the rest of the day?
"First in the morning I wrote"
So did you wake up early this morning, or are you still up from the night before, like me?
-- "Government is the great fiction through which everybody endeavors to live at the expense of everybody else."
1) Use python with C bindings
Why not fork?
It's kind of funny how this guy voluntarily slashdotted himself by submitting an article with a link to his own site, crashing it instantly. :)
I'm going to start putting that at the end of everything I write so that people can't criticize anything I do. As a matter of fact... I think I'll only write on Sunday mornings after not sleeping the night before. It seems like it's always Sunday morning anyways.
Sex - Find It
You must be to ask slashdot's opinion of your toils!
--Keeping the flame wars alive, one post at a time
"Secure, Efficient and Easy C programming in 24hrs"
Impossible. C, itself, is a bad habit.
why not just use visual basic?
say what you want about it, you don't have to use stupid hacks to avoid buffer overflows.
Perl is for idiots who think regexps can solve all problems.
s/idiots/wise souls/
s/think/know/
Problem solved.
I write in my journal
do us all a favour
favour? favour? what are you, the fucking queen or something? god save this, you crusty old bitch.
Boehm GC can't do much with C.
I find it somewhat ironic that you make claims like that, and that you write a memory management HOWTO at the same time.
But eh, keep hacking at that square wheel.
A message from the system administrator: 'I've upped my priority. Now up yours.'
Damn true, using C for other thing than low-level stuff really is a bad habit.
Oh, God, another Visual Basic user who writes code with a mouse. Spare me.
Well, I'm getting a bit tired of arguing. Even it the speed didn't matter at all, there's still the point that you can't create easily usable GC with C portably. And I don't feel restricted at all with the data stack. Yes, it's a bit more restrictive when comparing to fully automatic GC, but still much less PITA than having to free() the memory which everyone else are doing.
I don't care about speed that much. Portability is one however which I really do care about and I'd hate to depend on requiring an implementation of GC for some specific platform I intend to use.
Telling GC about all your structures sounds much more difficult and error-prone to me than my simple data stack.
Damn true, using C for other thing than low-level stuff really is a bad habit.
Oh, God, another Visual Basic user who writes code with a mouse. Spare me.
Yes, because it's better to spend weeks and months carefully constructing a GUI by hand then to put it together in a couple days with a mouse. Especially if it's going to be used by three or four people; by God, it's more than worth it to the company for me to spend two or three months on the project (@ $60,000 a year) so those people can get their results back in a couple seconds rather than a couple minutes.
It's also better to spend weeks and months writing an efficent text processing program in C and worrying about buffer overflows and memory leaks, rather then writting it in a couple days in Perl or Snobol. Who cares that the results will inevitably be piped to less and studied for a few minutes; the fact that we shaved off 40% of 2 seconds (and added an obscure error case) is more than worth it!
Actually: Oh, God, another C programmer that will make me suffer through anonymous core dumps because his programming language is so much more macho, and so much more efficent (really wish he understand how to use Big-O notation and switch algorithms, but he spent so much time programming this one and dubugging it that he can't afford to switch. Too bad he doesn't use a language with efficent control structures predebugged and optimized.)
Did I sense irony? :-)
But my infinite loops runs *so* fast!
And what would I do without my precious core dumps?
I can't trust the computer to manage his memory!
Who cares about algorithms if the language is fast?
I could not live without '\0' delimited strings!
Strong typing sucks. Dynamic typing sucks. I like my types to have no purpose other than sizing the fields in memory.
Error control and safety are for wimps.
Macros should be dumb text substitution tools.
A message from the system administrator: 'I've upped my priority. Now up yours.'
I'm tired of this constant discrimination against the citrus fuits. One of these days the people will get up and say "I'm tired of people thinking that oranges aren't good enough for comparison." They'll say "I can compare apples and oranges". They'll run to the windows and say "This orange is much yellower than this apple". People will be running through the streets screaming "This apple is much more smooth than this orange."
And then my group(The People for the Ethical treatment of Cirtrus (PETC)) will be happy.
*Not a Sermon, Just a Thought
*/
[Those] that can give up portability to obtain a little temporary security deserve neither portable code nor secure code.