News for hackers. Stuff that matters.
Re:Remote code execution, git, and OS X by pjmlp on Monday April 18, 2016 @08:37AM (#11519408)
I agree with you, the only problem being that even in 2016 there are shops that prohibit the usage of STL.

The real way out is to eventually change to a language where safety is opt-out and not opt-in, like in C++.

Re:Remote code execution, git, and OS X by w8rbt on Monday April 18, 2016 @10:20AM (#11520059)
C++ is far safer than C precisely for the reasons listed. The standard is safe by default (it's not opt-in). If you want or need backward compatibility with C, then you can use the more error prone C constructs for that. Otherwise, pure C++ code is safe.
Re:Remote code execution, git, and OS X by pjmlp on Monday April 18, 2016 @10:50AM (#11520317)
It is opt-in, because it depends on the STL, which many shops forbid.

I have always been on the C++, in the C vs C++ wars, but I am also aware of all those developers that just code C with a C++ compiler, hence opt-in.

Re:Remote code execution, git, and OS X by ryandrake on Monday April 18, 2016 @01:57PM (#11521846)
I'd hope people are not using the STL nowadays, in favor of the C++ Standard Library which is part of the C++ standard.
Re:Remote code execution, git, and OS X by pjmlp on Monday April 18, 2016 @02:35PM (#11522138)
People like myself that know C++ since the "C++ Annotated Reference Manual" tend to keep using STL to designate the standard library, but I guess you already knew that.

If it makes you happy I can use the ANSI C++ section number instead.

Re:Remote code execution, git, and OS X by ryandrake on Monday April 18, 2016 @03:40PM (#11522582)
Wasn't sure if that's were you were going. So, who in this day and age, forbids the use of the standard library? That seems pretty bizarre. What would be the motivation behind such a policy?
Re:Remote code execution, git, and OS X by pjmlp on Monday April 18, 2016 @04:28PM (#11522938)
The arguments against it are usually that it is too bloated, too slow, makes use of templates and exceptions.

So any place that is against templates and exceptions, usually rules out the standard library on those arguments.

Then you have the software houses, whose C++ code is actually C with a C++ compiler that use the bloat and slow arguments against the library.

I don't remember them by heart, but there were a couple CppCon 2014 talks where this type of arguments was discussed.

Re:Remote code execution, git, and OS X by ryandrake on Tuesday April 19, 2016 @11:28AM (#11527629)
Whenever someone complains to me that the standard library is slow or "bloated" (whatever that means), I ask if they've ever profiled their code vs. the standard library version. 9 times out of 10 they have not, and are operating out of mythology rather than measurement.