Slashdot Mirror


User: c

c's activity in the archive.

Stories
0
Comments
1,798
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 1,798

  1. Re:it's a C idiom on C Code On GitHub Has the Most "Ugly Hacks" · · Score: 1

    I've been coding in C long enough to know the difference between unspecified/undefined behaviour and bona-fide bugs.

    For example, I'm pretty darn sure that a chunk of code such as:


    unsigned char inbyte;
    read(fd,&inbyte,sizeof(inbyte));

    should always read at most the same number of bytes (one byte would be nice, but let's pretend we're non-POSIX, here...). And if you *change* that chunk of code to something like, say:


    unsigned char inbyte;
    assert(sizeof(inbyte)==1);
    read(fd,&inbyte,sizeof(inbyte));

    It should *still* read at most the same number of bytes as the first chunk of code. If the second chunk of code reads 1 byte while the previous chunk of code was reading 2 bytes (and, incidentally, bashing the stack while dumping those 2 bytes into a 1 byte variable), I'm comfortable in calling that a compiler bug.

    Mid-late 90's Visual C++, in case you weren't aware, was not a good vintage.

  2. Re:it's a C idiom on C Code On GitHub Has the Most "Ugly Hacks" · · Score: 1

    "/* ugly hack to... */" is a modest expression of pride describing concise, functional, readable and elegant C code...

    Speak for yourself.

    I usually use the expression "ugly hack" to describe the stupid shit I need to do to get around compiler or library bugs.

  3. Re:File this under "NO SHIT" on C Code On GitHub Has the Most "Ugly Hacks" · · Score: 1

    Because it is by design able to access a hell of a lot more than other languages. How many languages have direct hardware access? Or inline ASM code?

    Amen.

    As a rule of thumb, any code (in any language) that deals directly with hardware and doesn't have at least a few commented hacks should be treated with suspicion. It likely either doesn't work, the hackery is too subtle for mortals to comprehend, or the person writing the code is so clueless that they don't recognize when they've transgressed into writing horrible hacks.

  4. Why a classroom? on The Future Deconstruction of the K-12 Teacher · · Score: 1

    So, basically, it's going to be just like school is today, except the teachers will be working remotely?

    I suspect that veteran teacher has been doing it so like that he can't get outside of the box and imagine education without classrooms, schools, or even structured classes.

    I think the future is going to look a lot more like home schooling (possibly in groups to get around the whole school-as-babysitter issue that allows parent to hold jobs) than anything close to the institutions teachers currently work in.

  5. Re:Protect the income of the creators or they can' on Music Industry Argues Works Entering Public Domain Are Not In Public Interest · · Score: 1

    Copyright needs to (I reckon) end with the death of the creator; simple.

    Given that we've established that the entertainment industry is a collection of sociopathic asshats, are you quite sure you want to give them a genuine monetary incentive to, say, kill copyright holders in order to plunder their now-orphan works?

    Then there's the whole question of figuring out if/when a creator died.

    A reasonable fixed term from publication/creation makes the most sense. Emphasis on "reasonable".

  6. Re:Wait, what? Even in offline mode? on iOS WiFi Bug Allows Remote Reboot of All Devices In Area · · Score: 1

    34% of users can't tell their iPhones not to connect to a hotspot named attwifi. That sounds like the ability to force connection to a WiFi network to me.

    I'm thinking that if a malicious hotspot cycled through the known pre-installed SSIDs like "attwifi", common open SSIDs like "linksys", "NETGEAR", "dlink", "default", etc, plus corporate branded/hotspot SSIDs such as whatever Starbucks or McDonald's use, they could easily increase the vulnerable population to well over 75%.

  7. Re:How is it working in offline mode on iOS WiFi Bug Allows Remote Reboot of All Devices In Area · · Score: 2

    Don't worry, after a while you'll stop caring about having anything correct in the summary at all.

    Then you'll be fully qualified as a Slashdot editor.

  8. The only time I have ever been aware of hitting a mobile site is when you have that "gah, WTF is this crap?" moment where you can't find anything and the link you followed has been swallowed by the crap which has said :"hey, you're on a mobile, how about we fail to show you what you were looking for?".

    Their guidelines suggest suggest this is one of those things that will be punished. Which makes this smartphone user quite happy.

  9. It's a start on Google Adds Handwriting Input To Android · · Score: 1

    I'm kinda hoping that having a handwriting engine allows them to do something useful, like OneNote-style integration with Google Docs.

  10. What's worse than the apps on an Apple watch?

    A 2 hour podcast about the Apple watch.

    Keep in mind that you're looking at people who spent hours upon hours writing blog posts speculating about the leather and alloys Apple would be using in their watch bands.

    A 2 hour podcast about an actual shipping device seems comparatively reasonable.

  11. Re:Meh on Cyanogen Partners With Microsoft To Replace Google Apps · · Score: 1

    Yeah the MS junk won't be installed into CM just yet - but wait until that "Deep integration" Kirt McMaster keeps talking up starts happening - you're going to see architectural changes happen in CM designed solely to be beneficial to Microsoft.

    Well... I'm less certain of that.

    CM/Cyngn has to walk a fine line between making investors/partners happy and not pissing off the CM community. They don't make money from the community, but the community is a huge QA base and they'll have a lot of trouble developing and supporting Cyanogen OS without it.

    If they ram through MS-specific stuff (versus just expanding the capabilities of the OS for everyone), a huge chunk of the community is going to bail on them.

    I don't think they're quite stupid enough to do this. But I did say "Yet", because ... well, aside from their inability to muzzle their CEO, publicly fucking over a loyal customer with an international reach in favour of a regional exclusive was easily one of the most boneheaded things I've seen in a while. Short of changing the default boot animation to an android waving its dick around, I can't imagine a much more effective way to scare off potential Cyanogen OS customers...

  12. Re:Meh on Cyanogen Partners With Microsoft To Replace Google Apps · · Score: 1

    So far that seems to be the major target market. As long as the carriers are heavily involved in choosing and customizing phone for consumers as they are in the US and Canada, I doubt you'll see a CM-based phone get much traction over here.

  13. Meh on Cyanogen Partners With Microsoft To Replace Google Apps · · Score: 3, Informative

    It maybe sucks for those who buy a phone with CM pre-installed, but they've already announced that there's no plan to install any MS junk into CyanogenMod, and it's highly unlikely that the community would stand for it if they tried.

    So, not something to worry about terribly much. Yet.

  14. Re:Technically right on Google Responds To EU Antitrust Claims In Android Blog Post · · Score: 1

    That's probably because somewhere in the google complex, there are some crusty old bureaucrats that just cant let go of the notion that "Proprietary == Profit!", and that "Control" takes many forms other than just "Stop all competition at all costs!"

    I think it's just as, if not more, likely that within the Google complex the general mindset is that any Google service in Android (or more generally, on the web) is going to so much better than any competing service that nobody in their right mind would care about that competing service.

    Which isn't an entirely unreasonable opinion/bias if you think of it from their perspective. There's obvious counter-examples like Google+, but in the case of the core services like search, maps, their app store, etc, it's... well, I don't think it's the slam-dunk Google might think it is, but there's at least a rational basis for having that bias.

    To some degree, that's where this EU action leaves a sour taste... there might be a basis for some action (scraping competitors websites for data to use in a shopping service *does* sound pretty dodgy), but the overall tone of it seems like the EU attempting to punish Google for sincerely believing that their own products are best of breed in their respective spaces.

  15. Re:ASCAP and BMI on Legislation Would Force Radio Stations To Pay Royalties · · Score: 3, Funny

    Someone needs to come out with a diagram of how, what, and who gets paid in the music business.

    Risky. On one hand, you might just end up with a diagram telling you where the buck stops. On the other hand, you might end up summoning the Elder Gods.

  16. I'd probably start with... on Researchers Developing An Algorithm That Can Detect Internet Trolls · · Score: 1

    ... something like this:


    int is_troll( const char* username ) {
          if( !whitelisted(username) ) {
                return 1;
          }
    }

  17. Re:Brand names mean a lot in some places on Best Buy Kills Off Future Shop · · Score: 1

    What I've seen is that american brands have had trouble penetrating that market because preference goes to the incumbent local company.

    There's a certain amount of truth there. But there are also counter-examples. Walmart, in particular, destroyed quite a bit of the competition (Woolco, K-Mart, Zellers, etc).

    And then there's cross-border shopping...

    Target is struggling to gain acceptance

    Well, not anymore. The best I can determine is that Target's approach to the Canadian market was to push brand recognition, but their supply chain, pricing, and how they ran their stores was jarringly different from how they ran them in the US, and enough Canadians knew the difference that once the word got out, the impression was they were trying to milk Canadians without bringing anything new to the table.

    Canadian Tire is still the go-to

    Canadian Tire hits a real sweet spot in terms of locations, pricing and selection. I can't really think of any other competition which covers quite the same ground.

    even major e-tailers like Newegg have trouble over the other Canadian e-tailers

    True. I think ncix.com was solidly established well before Newegg opened a Canadian store.

    The problem for these companies is that their .ca sites routinely offer less to Canadians at usually substantially higher prices than their .com's, and while there may be legit business reasons, nobody likes being treated as a second-class citizen. So there's always a bit of resentment.

    Hell, Sears seems to have won mindshare by having a little maple leaf in their Canadian logo.

    I think Sears won mindshare in Canada from catalog sales. There are Sears mail-order outlets in every stinking little town across the country, and Canada has a lot of stinking little towns; up until maybe 10-15 years ago when e-commerce took off they were the household name for remote purchasing. But they're no longer the only game in town, and their supply chain is still stuck in the 90's; I can buy Craftsman parts directly from China faster and more reliably than I can get them from the local Sears parts store. I'd be very surprised to see them last another five years.

  18. Re:Not a huge surprise on Best Buy Kills Off Future Shop · · Score: 1

    I shopped more at Best Buy than FutureShop because Best Buy sales reps were not on commission while FutureShop sales reps were (and, as a result, tended to be very pushy).

    It might be a local thing, but I've found that the Future Shop employees generally leave... sorry, left me alone unless I hunted one down and asked questions. The few times I bothered with Best Buy I either couldn't find an employee willing to answer questions or couldn't find the product I needed.

  19. Re:Not a huge surprise on Best Buy Kills Off Future Shop · · Score: 1

    I wouldn't be surprised if there was requirement like that... maybe 5 years on the outside. But 14 years?!? That's eons by corporate standards.

  20. Re:First RadioShack, now Future Shop!? on Best Buy Kills Off Future Shop · · Score: 1

    I'd say they were a mob front ... except they're owned by Bell Canada these days.

    s/except/because/ strikes me as more accurate.

  21. Not a huge surprise on Best Buy Kills Off Future Shop · · Score: 4, Insightful

    The real surprise is why it took so long? 14 years is a heck of a long time to be running large redundant stores. From the parking lot of my local Future Shop, you could literally see the Best Buy store, and neither store was ever busy enough to really justify having two so close together, and I've heard that some were so close as to share a parking lot. It might be different if there were significant differences in the product lines they carried, but as it is it never really made much sense.

  22. Re:I hate not being culture on Quebec Plans To Require Website Blocking, Studies New Internet Access Tax · · Score: 3, Informative

    This is one thing I wish the US could import from France. Over there, all radio stations, newspapers, and other places have to have a percentage of their artists be local to that country.

    Canada has that sort of system, too, to protect local "culture" from the US marketing behemoth.

    When it works, it seems to work pretty well.

    The main issue with that sort of system is that it's based on a minimum quantity of local content. Yes, you do get some good local talent which you might not hear about otherwise. Unfortunately, most of the time you just get Nickelback.

    I think the majority of Canadians would prefer to just drop the CanCon requirements entirely.

  23. Re:Easy Solution on Broadband ISP Betrayal Forces Homeowner To Sell New House · · Score: 1

    I guess it depends on what the fine is for not complying. For your above scenario to make sense, the fine itself would have to be more than the cost of installing the line.

    It doesn't have to be a big fine. It just has to be a fine that continues to apply until they install it. $50/day until the service is turned on would get compliance... eventually.

    Once they've installed your lines, you're basically a slave to paying that provider's rates.

    That's a tougher problem, but I'm sure it could be managed.

  24. Re:This is the dumbest research I've seen this yea on No, It's Not Always Quicker To Do Things In Memory · · Score: 1

    Well, that's pretty lame then. They did say "sync" in the paper, but I didn't get to the actual code since, quite frankly, I was being blinded by the daylight already coming through the holes in the rest of the paper.

  25. Re:This is the dumbest research I've seen this yea on No, It's Not Always Quicker To Do Things In Memory · · Score: 1

    Their "writes to disk" are just being stored in disk cache hence the "faster" speed.

    According TFA, they actually do an explicit sync to disk at the end of the writes. So it's not purely writing into cache.