US food producer Ralcorp has reported a slight decline in quarterly net earnings, hit by higher ingredient costs.