Slashdot Mirror


User: Joce640k

Joce640k's activity in the archive.

Stories
0
Comments
11,688
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 11,688

  1. Re:A damn good reason to learn security best pract on Is IoT a Reason To Learn C? (cio.com) · · Score: 0

    If you cant sort out a buffer overflow then dont call yourself a programmer.

    If you can't see that std::string is a better choice then don't call yourself a programmer.

  2. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 1

    I manage a 500,000 line C++ program which does a lot of memory management. There's exactly nineteen "delete" statements in all that code and the last one was added about 10 years ago. The person who adds number 20 has to invite everybody out for dinner.

    Nobody in the last ten years has done any manual memory management in this program or had a leak or a dangling pointer. It also closes all files promptly, etc. (try getting a garbage collector to do that!)

    Whatever else Rust may do, C++ memory management isn't one of the problems it solves.

  3. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 4, Insightful

    Right, but it's shitty for the programmer to manage it manually, isn't it?

    Not as shitty as having to guess when Java will close the file you just wrote (eg. so you can copy it to a USB stick).

    Resource management is much more than RAM, it's files, network connections, etc. Garbage collectors handle RAM OK but they're really really crap for everything else. In reality languages like Java need just as much manual resource management as C.

    The only language which really doesn't need manual work is C++. C++ has stack unwinding. C++ frees resources immediately when objects go out of scope, not when some garbage collector decides to wake up (which might be "never" - your file might _never_ close unless you quit the program).

  4. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 1

    What can you do in C about memory management?

    Simple: Use C++ memory management instead. Your existing "C" compiler can probably do it if you let it.

    When you're there you might find you enjoy some of the other features too.

  5. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 0

    Here is a good reason not to learn C: shitty memory management.

    Yep, and that's where C++ came in.

    NOBODY should be writing real code using malloc/free. Use std::string and std::vector instead. You can use them perfectly well in "C" code so there's no excuse.

  6. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 1

    C++ powers the entire Arduino ecosystem. Chips with 32kb flash and 2K RAM are happily running C++ all over the world as we speak. Most of those programs will run on chips a quarter of the size (the Arduino IDE prints out how much flash/RAM your program uses on every upload to the chip so you can see it).

  7. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 1

    C++ has no overhead compared to C unless you choose it. The most repeated phrase in C++ design was/is "you don't pay for what you don't use".

    eg. If you choose to use virtual functions in classes then there's some overhead. If you don't, there isn't. Your choice.

  8. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 3, Insightful

    Complete bollocks.

    I use C++ on a day to day basis on Atmel chips. I've written ray tracers in C++ on chips with 4K Flash and 128 bytes of RAM using ordinary "float" data types.

    The entire "Arduino" ecosystem runs on C++, driving 3D printers, robots, etc. on tiny microcontrollers. How do you explain that Pesky Fact?

    Java, Python and VB.net don't have a snowball's chance in hell of running on one of those chips.

    (Most likely you've never even used C++, you're just repeating crap you once read on the Internet)

  9. Re:Until on Is IoT a Reason To Learn C? (cio.com) · · Score: 1

    C is at the very minimum a way to make things portable. C++ is not.

    This isn't 1992.

    Do you know any platforms where there's a C compiler but not a C++ compiler?

  10. Re:An example for rest of the nation. on ISRO Makes History, Launches 104 Satellites With Single Rocket (indiatimes.com) · · Score: 2

    Donald Trump will soon put a stop to this.

    96 American satellites had to be launched by a third world country? That doesn't make America look great.

  11. Re: Low Interest In The Public on Encrypted Email Is Still a Pain in 2017 (incoherency.co.uk) · · Score: 1

    Diffie-hellman key exchange appended to the first few emails you send each other. After that full encryption and an easy way for users to compare their private keys with each other if they really want to.

    Most of them won't ever check them and that's perfectly OK. One in ten thousand people checking their keys is enough to spot a mass man-in-the-middle attack by the NSA (and I'm sure there's plenty of security researchers who'll sit all day long testing the system).

    eg. Whatsapp does it by showing your key and a QR code of it on screen. People can validate the key by pointing their camera at your phone. That's easy enough for anybody to do.

    PS: Hats off to Whatsapp for doing this.

  12. Re: Arrest him and throw him into Gitmo on US-Born NASA Scientist Detained At The Border Until He Unlocked His Phone (theverge.com) · · Score: 1

    Me? I've visited two other countries so far this year (and it's only February).

    From my house I can drive to three different countries in half a day without even seeing a checkpoints.

    (unless it's an old abandoned one)

  13. Re:Low Interest In The Public on Encrypted Email Is Still a Pain in 2017 (incoherency.co.uk) · · Score: 1

    No, he wants to scrap it. Completely.

    He wants to scrap what he doesn't understand.

    Nope, I want to scrap it, completely.

    There's absolutely no reason for every last email user to be in a ring of trust. We only need a small percentage of people to actually verify their credentials and it's enough to spot of the NSA is playing games with the system.

  14. And... don't you have to select a special "ludicrous" mode to get the car to accelerate that fast?

    This guy is just after money. I hope the judge throws him out and makes him pay for wasted time.

  15. Re:that's becasue PGP is terrible on Encrypted Email Is Still a Pain in 2017 (incoherency.co.uk) · · Score: 1

    Why isn't it automated? What's the reason?

  16. Re:Low Interest In The Public on Encrypted Email Is Still a Pain in 2017 (incoherency.co.uk) · · Score: 3, Interesting

    Rubbish.

    Not even the most non-techie user would turn down "encryption" if it was offered.

    The real problem is the stupid email software writers who insist on using "certificates", rings of trust, etc. I'm looking at you, PGP.

    Secure mass communications doesn't need all that, all they need is a way to exchange keys automatically and a way for people to compare key fingerprints if they suspect a man-in-the-middle. Whatsapp have managed it perfectly.

    It only takes a small percentage of the population comparing fingerprints to find out of the NSA is engaged in mass e-mail manipulation. Anybody worried about privacy can simply do the fingerprint check. No certificate authorities to pay, no rings of trust needed.

    If I was a conspiracy theorist I might _also_ suspect that the real reason it hasn't been implemented by major players (eg. Microsoft) is because the US government doesn't want them to.

  17. Re: Arrest him and throw him into Gitmo on US-Born NASA Scientist Detained At The Border Until He Unlocked His Phone (theverge.com) · · Score: 5, Insightful

    Papieren, bitte!

  18. Re: Arrest him and throw him into Gitmo on US-Born NASA Scientist Detained At The Border Until He Unlocked His Phone (theverge.com) · · Score: 5, Insightful

    That's not how border security works. They don't need a warrant. The courts have decided this.

    There was nothing illegal that happened here.

    Even if you're a returning US citizen?

    This word "freedom". I don't think you (or most of the USA) knows what it means even though you spend your entire lives repeating it.

  19. Re:Memory maps, undocumented op codes... on Ask Slashdot: What Are Some Things That Every Hacker Once Knew? (ibiblio.org) · · Score: 1

    I used to know a good part of the dos/pc memory map, and before that certain 8-bit micros.

    Yes, you youngsters had it easy...

  20. Re:Hexadecimal on Ask Slashdot: What Are Some Things That Every Hacker Once Knew? (ibiblio.org) · · Score: 4, Insightful

    Hexadecimal: what it is, why it is and how & why it evolved from octal.

    This word 'evolved'. I don't think it means what you think it means.

    Multiples of 4 bits (ie. hexadecimal) is more natural in a binary world.

    Multiples of 3 is stupid, it was only ever going to be temporary.

  21. Re:Zero Page memory locations on Ask Slashdot: What Are Some Things That Every Hacker Once Knew? (ibiblio.org) · · Score: 2

    and those who used one didn't use the other.

    Everybody knew both where I worked and we all moved the 68000 with no problems. All it takes it 10 minutes looking at clock cycles in the back of the manual.

  22. Re:bitwise math on Ask Slashdot: What Are Some Things That Every Hacker Once Knew? (ibiblio.org) · · Score: 4, Interesting

    For signed numbers, >> 2 and / 4 are not the same operation, so the compiler cannot do it for you.

    Of course it can.

    Compilers aren't AI, they can do any 'trick' the compiler writer knows, eg. using a shift instruction that preserves the sign bit. You need to disassemble some compiler output sometime and see the impressive amount of tricks they know. It's almost as if the compiler writers take pride in their work.

  23. Re:Money to be made... on Excessive Radiation Inside Fukushima Fries Clean-Up Robot (gizmodo.com) · · Score: 1

    After the disaster. Japanese seniors volunteered to do cleanup work as they thought they were near the end of their lives anyway.

    As opposed to Chernobyl, where many not-so-senior people went in to try and stop the leak?

    https://encrypted.google.com/s...

  24. Re:Coffee on Slashdot Asks: How Do You Know a Developer is Doing a Good Job? · · Score: 1

    When the coffee machine runs out :D

    There's no 'metric' that can't be gamed. If I was being paid to drink coffee I'd be emptying it into secret buckets.

  25. Re:Worked with digital TV on 86 Percent of New Power in Europe From Renewable Sources in 2016 (theguardian.com) · · Score: 4, Insightful

    Nuclear is 500% more expensive to decommission than was projected. And after that there are millions in costs to protect the decaying nuclear waste lest it be taken by terrorists.

    If only there were some new types of reactors designed after 1950....