
222 N.W.2d 467 (1974)
STATE of Iowa, Appellee,
v.
Laverne K. QUANRUDE, Appellant.
No. 56322.
Supreme Court of Iowa.
October 16, 1974.
*469 James U. Mellick, Waukon, for appellant.
Richard C. Turner, Atty. Gen., Raymond W. Sullins, Asst. Atty. Gen., and John W. Shafer, County Atty., for appellee.
Heard by MOORE, C. J., and REES, UHLENHOPP, HARRIS and McCORMICK, JJ.
McCORMICK, Justice.
Defendant was convicted by jury and sentenced for two violations of Code § 204.401(1), delivery of a controlled substance. One of the alleged violations occurred before the effective date of the statute. We find that conviction invalid because it resulted from ex post facto application of the statute. The other conviction is attacked on evidentiary and procedural grounds. We find that conviction should stand. We reverse one conviction, affirm the other, and remand with directions.
I. One charge, brought in district court on March 16, 1972, was delivery of a controlled substance, d1 amphetamine sulphate, to one Carl Christianson in Allamakee County on March 20, 1971, in violation of what appears in the 1973 Code as § 204.401(1). That offense was created by Acts First Regular Session 64 G.A., ch. 148, § 401(1), effective July 1, 1971. It carries a maximum penalty of not to exceed five years imprisonment and a fine of $1000. § 204.401(1)(b), The Code, 1971.
The same conduct was proscribed in § 204A.3(1), The Code, 1971, which was in effect on the date of the alleged offense. That offense carried a lesser penalty, a maximum penalty of not to exceed one year imprisonment and a fine of $1000. § 204A.10, The Code, 1971.
Defendant demurred to the county attorney's information, contending application of the new statute to conduct occurring prior to its effective date would violate the prohibition against ex post facto laws in Article I, § 9, cl. 3, United States Constitution. The State resisted, contending that § 204A.3 of the 1971 Code was repealed and unavailable and that the legislature intended the new statute to be applicable. Judge E. B. Shaw overruled the demurrer.
Later proceedings in the case were before Judge Joseph C. Keefe. In response to a pretrial defense motion, Judge Keefe held the new drug statute required that the State prove as part of its jury case, as a prerequisite to imposition of the felony sentence provided in Code § 204.401(1)(b), that the defendant intended to profit from the alleged delivery of the controlled substance. Cf. State v. Vietor, 208 N.W.2d 894 (Iowa 1973). The State amended the county attorney's information to charge delivery of the amphetamine "for profit" in conformance with the judge's ruling. Defendant did not renew his demurrer.
The State contends defendant waived any error in the ruling on his demurrer by not renewing it after the information was amended and not raising the issue in exceptions to instructions. We do not agree.
Code § 777.10 provides that if a defendant's demurrer is overruled, "the defendant has a right to plead to the [county attorney's information] * * *." Hence, a defendant does not waive a demurrer which is overruled by pleading over and defending the case on the merits.
Further, the amendment to the information continued the charge against defendant under the new statute. It did not affect the issue raised by the demurrer. Because it did not do so, and because defendant did not waive his demurrer by pleading over and defending the case on the merits, it was not necessary for defendant to renew the demurrer or to raise the issue again during trial.
The State does not defend the court's ruling on the demurrer, nor could it successfully do so. The ex post facto clause of Article I, § 9, United States Constitution, forbids application of a new punitive measure to conduct already consummated where *470 it operates to the detriment or material disadvantage of the accused. Accordingly, a punitive measure is ex post facto if it punishes past conduct which was not criminal when it occurred. It is also ex post facto if it increases the malignity of or possible penalty for past conduct which was criminal when it occurred. Lindsey v. Washington, 301 U.S. 397, 57 S.Ct. 797, 81 L.Ed. 1182 (1937). The State breached the ex post facto clause in this case by charging defendant with amphetamine delivery under a new statute carrying a greater possible penalty than attended the conduct when it allegedly occurred. His demurrer should have been sustained.
Apart from the constitutional issue, the new statute by its terms is applicable only to offenses occurring after July 1, 1971. Acts 64 G.A. First Regular Session, ch. 148, § 601(5) ("This Act applies to violations of law * * * which occur following its effective date.") The right to prosecute prior offenses under the repealed statute is preserved. Acts 64 G.A. First Regular Session, ch. 148, § 601(1) ("Prosecution for any violation of law occurring prior to the effective date of this Act is not affected or abated by the passage of this Act."), and § 605 ("[Chapter 204A, The Code, 1971, is] repealed except with respect to * * * penalties which were incurred * * * before the effective date of this Act."); see State v. McGranahan, 206 N.W.2d 88 (Iowa 1973).
The court erred in overruling defendant's demurrer. Defendant's conviction of amphetamine delivery is invalid. He is entitled to judgment dismissing the charge.
II. The other charge, also brought in district court on March 16, 1972, was delivery of a controlled substance, marijuana, to Carl Christianson in Allamakee County on July 24, 1971, also in violation of what appears in the 1973 Code as § 204.401(1).
Defendant entered a not guilty plea to this charge. Then, as he did on the other charge, he filed a pretrial motion attacking the constitutionality of Code § 204.410 insofar as it places the burden of proof on a convicted defendant to prove he was an accommodation offender in a post-trial nonjury proceeding, to avoid the felony sentence provided in § 204.401(1)(b). He asked the court to interpret § 204.401(1)(b), in light of the alleged unconstitutionality of the procedure in § 204.410, to impose the burden on the State to prove as part of its jury case that he delivered the marijuana with an intent to profit. The court sustained his motion. The case was tried and submitted to the jury on an amended charge of delivery of marijuana "for profit." The jury found defendant guilty of delivery of marijuana, "not for profit." He was sentenced to six months in the county jail as an accommodation offender.
Defendant now asserts this procedure was wrong and he is entitled to reversal of his conviction because of it. He relies upon State v. Vietor, supra, where, subsequent to trial court's ruling in the present case, this court held the procedure provided in Code § 204.410 is constitutional, and the same procedure as was employed by trial court in this case was found to be erroneous.
The difficulty with defendant's present position is he has not been harmed. At his request the accommodation issue was tried to the jury rather than the court. The burden of proving his intent to profit was, at his request, placed on the State. Defendant prevailed on that issue with the jury. He could not have had a better result, and indeed may have done worse, had the statute been followed. He is not prejudiced by the fact he prevailed with the jury rather than the court. We do not reach the question whether he could assert prejudice if the jury had not resolved the issue in his favor.
III. Defendant also asserts the evidence was insufficient to support jury submission of this charge. An undercover agent, Carl Christianson, testified he purchased marijuana from defendant on the occasion involved. He said the substance was given to Waukon police officer Gary *471 Klein the next morning. Klein testified he mailed it to the state criminalistics laboratory for analysis. A state chemist testified that, upon analysis, it was determined to be marijuana. Christianson's roommate, called as a witness by defendant, testified he observed the purchase.
Viewing the evidence in its light most favorable to sustain the verdict, we hold there was sufficient evidence to submit the case to the jury. See State v. Staker, 220 N.W.2d 613, 617-618 (Iowa 1974).
IV. In another assignment of error defendant contends trial court erred in overruling his objection to the offer of the marijuana into evidence. His only objection when the exhibit was offered at trial was to foundation, based upon an alleged deficiency in chain of custody between completion of laboratory analysis and offer of the exhibit. Our consideration of this assignment is limited to the issue raised in defendant's objection at trial. State v. Mathias, 216 N.W.2d 319, 321 (Iowa 1974).
We have examined the record in light of the principles enunciated in State v. Lunsford, 204 N.W.2d 613 (Iowa 1973). We there held that although a more elaborate foundation to establish identification is required for exhibits like marijuana which are susceptible to tampering or substitution, "It is not essential for admissibility that the State negative the possibility of tampering absolutely. It is sufficient to establish that it is reasonably probable tampering or substitution did not occur." Id. 204 N.W.2d at 617. A trial court determination that the identification is sufficient will not be overturned except for a clear abuse of discretion. Ibid.
The exhibit was a plastic bag sealed with masking tape, inside which was another plastic bag, containing plant material. Christianson testified the exhibit appeared to contain the substance sold him by defendant. He identified it by its packaging, appearance, and quantity. He said it was in substantially the same condition as when he turned it over to officer Klein. Klein testified without objection that the package contained marijuana and was the one he mailed to the state laboratory, identifying his initials on the masking tape.
Stephen C. Eck, a state chemist, testified the exhibit was the one he received at the criminalistics laboratory. He testified without objection that he analyzed the plant material and found it to be marijuana. He said he initialed the package. After analyzing the substance he repackaged it. He identified his intials on the package, said the exhibit appeared to be in substantially the same condition, and said it was still sealed in the same way.
Trial court did not abuse its discretion in admitting the exhibit.
We find no reversible error as to the marijuana delivery conviction.
Because defendant's demurrer to the county attorney's information charging him with amphetamine delivery should have been sustained, the case is remanded for judgment dismissing that charge.
Affirmed in part, reversed in part, and remanded with directions.
