Nebraska Wants To Adopt Your Kids

Senator Brad Ashford of Omaha has proposed criminalizing the act of keeping your kids home from school. This is abhorrent for many reasons, and should be withdrawn from consideration immediately.

Deputy Douglas County Attorney Kim Hawekotte and Ralston Public Schools social worker Steve Snodgrass, both active in truancy prevention in the Omaha area, said the proposed language change will make it easier for schools to identify students who are being improperly excused.

“By taking that sentence out,” Hawekotte said, “the schools have to react when a youth isn’t in school, no matter what the reason. You want the system to kick into place to make that determination.”

No, Ms. Hawekotte: you want the system to kick in. Our kids rarely miss school for non-medical reasons. However, sometimes we take advantage of educational opportunities that require a day or two of absence. As parents, this is our privilege and responsibility. It is not your job to second-guess our decisions.

As introduced, LB 1159 would get law enforcement, including the county attorney, involved earlier by making it an infraction to be the parent of a truant child. The first offense would prompt a $50 fine, the second, $100. The third would be considered a Class III misdemeanor, punishable by up to three months of jail time and a $500 fine.

We are considering taking a long weekend to Mt. Rushmore or Yellowstone National Park near the end of the school year. For various reasons, we might possibly have to make that trip while class is still in session. Mr. Ashford, your plan would require our school system to investigate us as criminals and fine us for teaching our kids first-hand about our country’s history, geology, and geography. Will you be passing a bill to take our kids on an equivalent field trip? Or will they simply miss out on that experience because likeminded senators deem themselves better parents to our kids than we are?

“If you’re not in school, you’re not learning,” said Ashford of Omaha, chairman of the Legislature’s Judiciary Committee.

Mr. Ashford, that’s one of the most offensively ignorant things I’ve read in a while. Formal education is critically important, but I assure you that my children learn outside the classroom. From teaching my kids to write computer programs, to learning French together as a family, to taking trips to national monuments and museums, they are learning.

I don’t want to downplay the need for kids to attend school as required, but completely reject your asinine assertion that their education ends when I pick them up from school.

The solution is simple: don’t fix what’s not broken, especially when the fix would cause even more problems. If a child is suspected of truancy, investigate that child. If a school system is unable or unwilling to do so, then address that problem. Don’t create an assumption of guilt every time a child misses school, though. You are not my kids’ parent. I am. Irk you though it may, I know more about what’s best for them than you do.

This bill puts State above Parent. Kill it.

You Want How Many?

I used to work near a little restaurant called “Rasta Grill”. It was this weird fusion of Italian and Jamaican food, and everything was absolutely delicious. We’d walk down to Rasta at least once a week or so and have giant plates of spaghetti with jerk chicken in the wonderfully bizarre atmosphere.

Well, we always suspected that some of the employees perhaps took the Rasta theme a little far, and occasionally partook of Jamaica’s other famous export. Our suspicions grew one day:

Us, ordering: …and an order of garlic bread.

Cashier: [writes “GBR” on the ticket, but draws the “G” almost like a “6”]

Cook, taking ticket: OK…. hey, what’s “6 B R”?

Cashier: That’s a “G”. It’s garlic bread.

Cook: [long, confused pause] And they want 6 of ’em?

Don't Bump That Flash Drive

From the manual of an Asus Eee PC:

The solid-state disk drive’s head retracts when the power is turned OFF to prevent scratching of the solid-state disk drive surface during transport.

I think someone got a little zealous with the find-and-replace.

Buffer Overrun In Antitrust

Skip this unless you’re really, really geeky.

Still with us? OK. In the movie “Antitrust”, there’s a screenshot of some code that has a possible Denial Of Service vulnerability:

/* are we doing a GET or just a HEAD */
boolean doingGet;
/* beginning of file name */
int index;
if (buf[0] == (byte)'G' &&
    buf[1] == (byte)'E' &&
    buf[2] == (byte)'T' &&
    buf[3] == (byte)' ') {
    doingGet = true;
    index = 4;
} else if (buf[0] == (byte)'H' &&
           buf[1] == (byte)'E' &&
           buf[2] == (byte)'A' &&
           buf[3] == (byte)'D' &&
           buf[4] == (byte)' ') {
    doingGet = false;
    index = 5;
} else {
    /* we don't support this method */
    ps.print("HTTP/1.0 " + HTTP_BAD_METHOD +
               " unsupported method type: ");
    ps.write(buf, 0, 5);
    ps.write(EOL);
    ps.flush();
    s.close();
    return;
}

Because I can’t resist such things, I paused the movie to read over the code. Now, I’m assuming this is Java instead of C++ because “boolean” wasn’t spelled “bool”, although I’m not sure why they’d be using Java for performance critical code. Anyway. See the ps.write(buf,0,5); line near the end? Well, “buf” is presumably the string that the client sent to the server. If the client is broken (or malicious) enough to misspell “GET” and “HEAD”, then the server politely tries to tell the client what it did wrong by sending “buf”’s value back.

Which brings us to the hack. If “buf” is less than five characters long, then that “ps.write” line will attempt to read past the end of “buf”. If the calling function doesn’t handle index error exceptions, boom! The service crashes: Denial Of Service. Note that this is still better than the C++ equivalent, which would write the contents of memory immediately following the end of “buf” back to the client.

No, I’m not exactly good at sitting back and watching movies.

How Not To Save A Game

I was about halfway through a game called “Final Fantasy XII: Revenant Wings” on my Nintendo DS. I was having a great time and loving it until a stupid bug wiped out all the work I’d put in and made me start over.

When I was in the middle of a particularly involved battle, the red “low battery” warning light came on, so as soon as I finished I tried to save my game. Big mistake. The DS used up its remaining power during that instant and turned itself off. When I plugged it into the charger and turned it back on, I got a message saying that my game file was corrupt and had been deleted.

OK, in retrospect, I should have plugged my DS into the charger before I tried to save my game. Still, it should be impossible to destroy your old information by writing a new version of it. That’s just good design. Unfortunately, FFXII doesn’t have a good design. See, the problem is that FFXII saves its game by writing over the pre-existing save file. Since the power died during that write, the results were half old game and half new game. Hence corrupt. Hence deleted. Here’s how a competent programmer would handle the same situation:

  1. Create a new save file and write the information to it.
  2. Delete the old file.

See the difference? At no point do the two files get mingled together, and the old file stays valid and ready to use until the new one is completely written. In the absolute worst case of a power failure during the saving process, you’d lose the new information but the old data would still be intact and safe.

I don’t know whether the buggy code was written by Square Enix, or if they were using Nintendo’s built-in game saving method. Regardless, it’s dumb and should be fixed ASAP for all new games.

Guest Post By Gabby Hatchetfish

The hatchetfish spends the day in deep water and rises closer to the surface at night to feed.It has light organs on its upper surface to attract small squid and other invertebrates.The hatchetfish also flashes its light organs on and off to communicate with others of its kind.