Want to know what the police can do -- in particular, where and how they can search a home -- when they find an unattended child wandering in the street? Then read this opinion. Which goes through all of the various cases in California that present this issue. Of which, sadly, there are quite a few.
Justice Robie authors a very good opinion here. It's comprehensive. It's moderate. It's well-reasoned. And it articulates a reasonable position that fairly attempts to balance both of the important competing interests at stake -- the privacy of the home versus the potential welfare of any occupants.
Ultimately, Justice Robie concludes that, under the particular facts here, it was reasonable for a police officer to look in a side window of the home. That counts as a search -- assuredly so -- but such a limited non-physical entry into the home was justified by the emergency aid exception. Reasonable minds might disagree about such a conclusion, but it seems a rational one, and Justice Robie's presentation of the issue is very persuasive. At least to me. (Thereafter, based upon what the police officer saw through the window -- a child playing with a plastic bag near an unresponsive adult -- the officer reasonably entered the home under the emergency aid doctrine, a result that seems entirely right.)
For you parents out there: Yet another reason not to let your young child wander alone in a street. Especially if you have a boatload of pot and meth in your house. Because the police can reasonably take a gander.