Childhood infections may increase the risk of developing certain mental illnesses in childhood and adolescence.