Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×

Comment Just check the file headers (Score 1) 74

When you're talking about PNG, if you're looking to avoid malicious files, you can just check the headers.
It's always the following decimal values:
137 80 78 71 13 10 26 10

Things get more tricky when you're talking about an exploitable file type, in which additional validation is required, but for most purposes, if the file being broken won't ruin the application, this is fine.

Comment And what about the infrastructure issues? (Score 5, Insightful) 294

While I'm not fully aware of the details of this story, it really seems to me that they are only looking to put the blame on the weakest side, which is obviously the workers. Even if the guy did screw up, it would be ridiculous to think a camera would be capable of preventing an accident. Where are the technical failsafes to limit the train's speed? Guess true security updates have been eaten by their desire for profit and instead been replaced with cheap cameras so they can say "oh no, we were watching the guy but he was a terrorist who shut down the camera" or any other crap to get their fat a$$es out of the way.

Comment Re:I don't know why people still say Java is slow. (Score 1) 382

Well, I used to think that too. In old times I'd agree 100% with you. I'm not gonna defend VB6, that was just a joke. But nowadays, javascript can run a lot faster than many compiled languages. You see things like Node.js which show that javascript engines have been insanely optimized, largely due to the languages (over)use on the internet. On my other post, I mentioned that Google made a demo using Dart (which is just a language which transcompiles to javascript, like CoffeeScript or TypeScript), rendering entire frames in 1.2ms. I am as much as baffled as you, but Google has found it easier to have low latency APIs for well-written JavaScript than with some Dalvik optimization.
My good advice is: it's hard for people with a compiled language background, including me, to accept that, but JS is very good for many things which we couldn't dream of 5 years ago, encroaching even C territory.

https://play.google.com/store/...

Comment Re:I don't know why people still say Java is slow. (Score 4, Insightful) 382

On a slightly more serious sidenote, it's easy to see Java's popularity dropping, since Google seems to be dumping java for high performance javascript/dart development, as they have already been announcing for Android.
http://arstechnica.com/civis/v...

Linus has actually stated it in a way that is frequently seen as toxic. But, while C++ is one of my favourite programming languages, certain language features tend indeed to "rotten" people's brains, just like pre-GIT CVS+derivatives did to source control habits. And I find that Java is actually the perfect representative of that nowadays, not C++ (and even Linus is now commiting patches in C++) I don't know what you guys people but when I have to traverse a tree of 10 folders, and files have 10 lines and exist only for a single abstraction's sake, I kinda feel OOP, though a powerful tool, has been overused. When everything has to be an object just for a paradigm's sake, things can get kinda distorted. One of the greatest programming innovations is, in my opinion, MVC (or even MVVC stuff like Angular) is one of the greatest things that have been getting popular lately. By separating logic from models and views people are encouraged not to create stupid abstractions and use procedural programming where it is adequate and avoid performance losses.

(proof that torvalds actually uses C++ if anyone hasn't seen that: https://github.com/torvalds/su...)

Comment I don't know why people still say Java is slow... (Score 5, Funny) 382

Maybe it's the applications. As you note, we have proved, time and time again, that in contrived scenarios Java code can meet or even beat the performance of so-called "performant" languages like C, C++, Lisp, VB6, or JavaScript. And when presented with such evidence, most sane, open-minded opponents will hang their heads in shame and promise never again to spread such slander.

...but then, they fire up Eclipse, or NetBeans, or Guiffy, or enable the Java support in their browser, or try to run an app on their favorite feature phone. And they wait for it to become responsive...

...and wait...

...and wait...



...and wait...







...and wait...













...and...






...what did I promise never to do again? Sorry, must have dozed off...

Comment Re:All your genes are belong to us! (Score 1) 333

Well, not correct. Endogenous opiates include endorphins, enkephalins, dynorphins and, surprisingly morphine itself (http://www.ncbi.nlm.nih.gov/pubmed/10941194).

Morphine has particularly bad side effects when taken orally. But no endogenous opiate release can ever match the dopamine release of even small opioid intake. Anyone who's ever taken (pharmceutical) opioids for any reason surely understands why one gets addicted to those. Having happiness anxiety-be-gone pills in your pocket can be tempting.

And what's even worse: unlike true depressants, up to a certain threshold there is almost no effect whatsoever on cognitive performance and will not make you sleepy. So when used in a certain way people get happy and work (and even find work interesting). It is said that chinese immigrants making use of opioids to work better in factories resulted in prejudice which led to opioids being banned in the United States.

Comment Re:News for shills, stuff that costs money (Score 2, Insightful) 241

Oh hey, this whole site is ridiculous, isn't it? Look, they talk about computers, computers cost money... And cellphones? Have you seen how expensive these are, gosh... Thank god we live in the United Federation of Planets and don't use this kind of thing anymore. Hey computer, where's my free coffee?

Comment author's interests (Score 1) 184

They must be talking about their own low quality SSDs. For online storage, the crappiest Samsung SSD will probably outlast your data. The best ones will outlast any old fashioned hd out there. As for offline storage, if you won't touch the data for months, using HDs is just stupid. You're better off with tapes.

Comment Still the "best" office suite. (Score 2) 130

It may be a little tragic. Microsoft, may be hated, but it's still by far the best (or standard) office suite. We should actually be happy they're still selling the old standalone office without price hikes (Adobe don't seem to be doing that anymore with the Creative Suite). Heck, now they're freely offering almost fully functional multiplataform versions of office for phones and tablets. Nowadays, it's actually believable that some day they may actually release a working Office Suite for Linux.

Sure you can use Open/Libre Office and be happy with it for several purposes, but the small incompatibilities are surely gonna cause you serious trouble once you can't see properly the documents you need. Even iWork, actively developed by what is now the world's biggest private company, eventually gets broken by something and eventually many users install Office for their needs. For work or study purposes involving constant document exchange with users which you can't garantee will use the same tool as you, I still see dropping Office as no go, and it may be ever so. It's just like image editing: Gimp works fine for most personal projects but if you do it for a living, unless you're lucky and find an opensource haven nobody is gonna hire you don't use Adobe tools.

You're not coerced into using any of the optional cloud features if you don't want to give Microsoft your data. I for one, got one free office 365 license with a new computer and one from work, and the desktop version still works fine and, except for the 1TB onedrive which is useful, I haven't moved on and used it because I prefer the standalone version, and besides frequent upgrades which I will obviously miss, even some quite good cloud integration is available trough the bundled onedrive if that's your thing. Also, all questioning that sould sincerely check if their questioning behaviour with their Android or iOS phones is similar, which would surely make the complaints rational questioning of a huge powerful corporation, or whether it's just hate of Microsoft and love of Google or Apple, which have been doing much worse than Redmond.

Slashdot Top Deals

He has not acquired a fortune; the fortune has acquired him. -- Bion

Working...