This is an appeal by cross-complainant Central Surety and Insurance Corporation, from a judgment of dismissal entered in favor of cross-defendants Foley.
Several cases were consolidated for trial in this litigation, growing out of a construction project on Telegraph Hill in San Francisco. However, we are concerned only with that phase, the facts of which follow: Appellant was surety upon the bond given by respondents Foley for their building contract with Albert and Margaret Merrill. Respondents became involved in a dispute with the Merrills, who sued them and appellant, which in turn cross-complained against respondents, alleging that the terms of the “Application for Contractor’s Bond,” which it attached to and incorporated in its pleading, entitled it to indemnity from respondents against any judgment or claim rendered against it, and that it was further entitled to a deposit of collateral to secure it against “any loss, costs or damages” for which it might become liable. Appellant alleged that it had demanded that respondents de *740 posit the required collateral, but that respondents had failed to do so. Appellant therefore prayed (1) that the court order respondents to deposit collateral in the sum of $7,500; (2) that in the event judgment were rendered against it, the court award it damages in that amount over against respondents; and (3) that it be awarded judgment against respondents for the costs of investigation and attorney’s fees which it had incurred. Appellant did not specify the amount of costs which it had allegedly incurred.
In due time respondents filed their answer to the cross-complaint, alleging a breach of the indemnity agreement on the part of the appellant, which deprived it of any right to a deposit of collateral, and then by a pleading which respondents designate a “re-cross-complaint,” they purport to set forth a cause of action for allegedly wrongful conduct in seeking to compel respondents to settle the dispute over the construction contract with the Merrills and its consequent delay, to the detriment of respondents in a substantial sum.
To this “re-cross-complaint,” without any question as to its propriety (see Code Civ. Proc., § 442), cross-complainant interposed a general denial.
On March 20,1961, approximately two years after the filing of the original cross-complaint, appellant served and filed an amended cross-complaint, in which it repeated the allegations of its original cross-complaint and added that, as of December 7, 1960, it had incurred attorney’s fees and engineer’s fees, court costs, and investigation expenses, in the amount of $4,173.60.
On March 31,1961, the matter came on for trial. Appellant moved that the amended cross-complaint be filed, whereupon respondents objected on the ground that appellant had not complied with the requirements of Code of Civil Procedure, section 473, that such an amendment be made upon motion and after notice to the adverse party. Respondents also urged that the indemnity contract had been executed on May 2, 1956, and that the cause of action was therefore barred by the four-year statute of limitations. The court agreed with respondents, sustained their objection with prejudice, and refused to permit the filing of the pleading, either as a supplemental complaint or as an amended cross-complaint.
Appellant then announced it would proceed to trial upon its original cross-complaint. Counsel for respondents objected on the ground that the main action had resulted in a judgment against the Merrills in favor of respondents and appel *741 lant, and that there was thus no need for a deposit of collateral and no judgment or claim as to which appellant could seek indemnity. As for appellant’s purported cause of action for attorney’s fees and other costs, respondents argued that neither of these items were mentioned in the body of the complaint. Also, respondents asserted that fatal to appellant’s claim was its failure to specifically allege the amount of said fees and costs. Again the court agreed with respondents’ contentions and rendered judgment in favor of respondents, who then voluntarily dismissed their "re-cross-complaint, ’ ’ which makes superfluous any discussion directed to the determination of this unique document’s niche in the law of pleading.
Appellant now contends that upon the record presented in this case, its original cross-complaint stated a cause of action for attorney’s fees and expenses, and that the court erred in summarily rendering judgment for respondents. This contention is sound. The lower court, in awarding respondents judgment solely on the face of appellant’s cross-complaint, was in effect ruling, as upon a general demurrer, that appellant had failed to state a cause of action. In
American Tel. & Tel. Co.
v.
California Bank
(1943)
*743 Since there can be no doubt that appellant’s pleading, if not already sufficient to state a cause of action for attorney’s fees and other costs, could easily have been amended to achieve that end, it is apparent that appellant’s right to indemnity was not terminated by the judgment against the Merrills.
As an alternative ground for the judgment, the trial court found that appellant had “failed to plead any items of damages and amounts thereof in detail and with certainty.” This defect in pleading was obviously not of sufficient magnitude to justify a final judgment against appellant. A mere failure to plead damages “in detail and with certainty” is the type of defect which is deemed waived in the absence of a demurrer on that ground.
(Wade
v.
Markwell & Co.
(1953)
In the present case, the lower court disallowed appellant’s amended cross-complaint on two grounds, the former of these being that the amendment was barred by the statute of limitations. This defense is completely inapplicable. Although
*744
it is true that the actual indemnity agreement between the parties was executed on May 2, 1956, and appellant’s amended cross-complaint was not filed until March 20, 1961, the time of filing the original pleading is still the date of commencement of the action for purposes of the statute of limitations, unless a wholly different case is pleaded by the amendment.
(Jones
v.
Wilton
(1938)
Although the trial court also based its judgment on the finding that appellant had failed to proceed by way of noticed motion as required under Code of Civil Procedure, section 473, the fact that a motion to amend is defective does not vitiate the court’s power to permit the amendment.
(Beverage
v.
Canton Placer Mining Co., supra,
at p. 778;
Stockton
v.
Newman
(1957)
In our opinion, the trial court clearly abused its discretion in disallowing the amendment with prejudice and in entering judgment against appellant on its cross-complaint.
For the reasons above stated, the judgment is reversed, with directions to the trial court to permit appellant to amend its cross-complaint.
Kaufman, P. J., and Agee, J., concurred.
