Q doing something blazingly stupid was a key part of his characterization, as essential as his hairstyle and mannerisms.
We must have seen a different movie, because in the one I saw, Q was pretty much a hardcore super hacker himself. Directly linking someone else's machine not only to your own, but directly to your entire network
, is... well, it's absolutely moronic. Especially
for anyone who's even mildly security conscious. Even if it's just his mother's laptop where all he needed to do was fix a setting in her web browser, he still wouldn't have plugged it straight into their network.
The writers were just unbelievably daft. Moreso than usual even, if for no other reason than that they were trying
to create a more realistic and believable Bond franchise.