African and U.S. officials reaffirmed their support this week for the African Union-led battle against al Shabaab, the Islamist militant group that controls much of Somalia. But these international efforts are being hobbled as African troops come under criticism for indiscriminately shelling Somali civilians.

The battle to bring stability to long-lawless Somalia, and to win the sympathy of its people, has played out in a giant open-air market in Mogadishu, where Somalis who buy vegetables, spaghetti, clothing and fuel are...