Opinion
WISEMAN, J.This case involves a dispute between a landowner and the state regarding the terms of an agreement under which the state took possession of land to build highway improvements. The landowner, a farmer, sued to enforce a provision he contends required the state to build an underpass beneath the improved highway to link parts of his farm on both sides of the road—an underpass that was never built. In his appeal, he contends that the trial court erred in (a) interpreting the agreement as imposing on the state only a duty to negotiate in good faith toward the *870building of an underpass, not a duty to build one; (b) limiting the owner’s damages to the cost of pursuing the fruitless negotiations (i.e., attorneys’ fees); and (c) ruling that he was not entitled to an order directing the state to build the underpass.
The state cross-appeals, arguing that the landowner’s suit should have been barred for several procedural reasons, that the evidence was insufficient to support the jury’s $40,000 verdict for failure to negotiate in good faith, and that certain evidentiary rulings and the refusal of a jury instruction were erroneous. We reject both parties’ contentions and affirm the judgment.
We publish our discussion of one of the state’s procedural issues: whether the trial court had discretion, after it sustained a demurrer, to accept the plaintiffs’ late-filed amended complaint, even though plaintiffs did not move for leave to file late. We hold that the court did have that discretion.
FACTUAL AND PROCEDURAL HISTORIES
Plaintiffs Floyd L. Harlan (as an individual and a trustee of certain trusts), Leola R. Harlan (as a trustee), and Harlan Land Company (collectively Harlan) own a farm in Fresno County. Highway 168 crosses the farm. Formerly, Highway 168 was a two-lane road that Harlan’s employees could cross at any point to move equipment and personnel from one part of the farm to the other. The California Department of Transportation (the state) wanted to take a strip of Harlan’s land to improve the highway by widening it to four lanes and erecting walls to limit cross-traffic. Harlan asked the state if it would include in the improvement project an undercrossing for its equipment and personnel.
For reasons related to its construction timetable, the state wanted to secure rights of possession and use of the land before formally obtaining ownership through eminent domain proceedings. The parties entered into an Agreement for Possession and Use (the Agreement) for this purpose. The Agreement provided that the state would receive irrevocable rights of possession and use and would pay Harlan $1,041,300. It contemplated a future “ultimate settlement” or an “award or verdict” in an eminent domain proceeding, which could result either in greater compensation to Harlan or a partial refund by Harlan. It was further “understood and agreed by” the parties that “in addition to the monetary compensation,” the “State’s ultimate settlement will include” construction by the state of an underpass at a stated approximate location. The Agreement stated that it was “made with the understanding that [the state] will continue to negotiate in good faith with [Harlan] to acquire its interest in the Parcels by direct purchase,” but that if no settlement was reached within a reasonable time, the state would proceed to acquire title by eminent domain.
*871The parties did not reach a settlement. The state filed an eminent domain action and Harlan filed this case. The two actions were consolidated. Before Harlan’s claims were tried in September 2003, the parties settled the eminent domain action and entered into a stipulation for judgment. The stipulation provided that Harlan would receive total compensation of $1,750,000 and reserved all the parties’ claims and defenses in this case.
In this case, Harlan’s second amended complaint was the operative complaint at the time of trial. It alleged that the state agreed in the Agreement to build an underpass and breached the Agreement by failing to build one. It further alleged that if the achievement of a final settlement was a condition precedent to the state’s obligation to perform its promise to build the underpass, that condition was waived by the state’s failure to negotiate in good faith toward a final settlement. The second amended complaint also alleged a cause of action for breach of the implied covenant of good faith and fair dealing. It requested damages and a declaration that the state was obligated to build an underpass.
The state moved in limine to limit Harlan’s damages to its out-of-pocket expenses in attempting to negotiate with the state about the underpass. The court granted the motion. It stated that the Agreement required the state to build an underpass only if an ultimate settlement was reached, and “[i]n the event there was not an ultimate settlement . . . matters would be resolved either through continuing negotiations or through an eminent domain action. In either event, the requirement of the State to build the underpass was not fixed, but was the subject of further negotiation.” Quoting Copeland v. Baskin Robbins, U.S.A. (2002) 96 Cal.App.4th 1251, 1262-1263 [117 Cal.Rptr.2d 875], the court ruled that, under these circumstances, Harlan could only recover “ ‘out of-pocket-costs in conducting the negotiations,’ ” and that it “ ‘cannot recover for lost expectations (profits) because there is no way of knowing what the ultimate terms of the agreement would have been or even if there would have been an ultimate agreement.’ ”
The jury found that the state breached the agreement and the implied covenant of good faith and fair dealing. It also found that “the State’s conduct excused, waived or estops the State from claiming any obligation to construct an undercrossing was subject to [there] first being a final settlement.” It awarded Harlan damages of $40,000, consisting of fees Harlan paid an attorney to conduct negotiations.
The state filed a posttrial motion requesting a determination that Harlan was not entitled to specific performance or a declaration that the state was required to build an underpass. The court granted the motion and issued a statement of decision. The statement of decision noted that in ruling on the *872state’s motion in limine, the court construed the “obligation of [the state] under the contract with respect to an undercrossing to be an agreement to negotiate toward a final settlement, not an agreement to build an undercrossing subject to a precondition of a final settlement.” The “parties never reached an agreement to construct an underpass,” so there was nothing specifically to enforce, and a declaration that the state was required to build an underpass would have no basis. The court observed that, “[although the jury found that State’s conduct excused, waived or estopped State from claiming any obligation to construct an underpass is subject to a condition precedent of final settlement, such finding of the jury is irrelevant in view of the court’s construction of the contract.”
The court entered judgment for Harlan for $40,000 on the causes of action for breach of contract and breach of the implied covenant of good faith and fair dealing. It entered judgment for the state on Harlan’s claim for declaratory relief. Harlan filed a notice of appeal and the state filed a notice of cross-appeal.
DISCUSSION
I. Procedural issues
The state makes three arguments which, if correct, would dispose of Harlan’s claims on procedural grounds. We reject these arguments.
A., B.*
C. Failure to file the second amended complaint by the court-ordered deadline
The trial court sustained the state’s demurrer to Harlan’s first amended complaint on September 12, 2002, and gave Harlan 10 days to amend again. The second amended complaint was not filed until September 30, 2002. Harlan never requested an extension of time. On October 30, 2002, the state filed a motion to strike the second amended complaint on grounds of untimeliness. The trial court denied the motion, stating that “the delay in filing was brief and inconsequential. The court will exercise its discretion in favor of denial of the motion. (Code Civ. Proc., § 475.)” The court also denied the state’s motion in limine to dismiss or exclude all of Harlan’s evidence on the ground that the late filing of the second amended complaint *873deprived the court of jurisdiction. It reasoned that the law-and-motion judge had acted within his discretion in excusing the late filing and denying the motion to strike. On appeal, the state again contends that the court lacked jurisdiction to hear the case because of the late filing.
Code of Civil Procedure section 475, which the trial court cited, provides that “[t]he court must, in every stage of an action, disregard any error, improper ruling, instruction, or defect, in the pleadings or proceedings which, in the opinion of said court, does not affect the substantial rights of the parties.” The trial court believed that Harlan’s late filing did not affect the substantial rights of the parties.
The state, however, relies on Code of Civil Procedure section 473, subdivision (a)(1), which provides: “The court may, in furtherance of justice, and on any terms as may be proper, allow a party to amend any pleading or proceeding by adding or striking out the name of any party, or by correcting a mistake in the name of a party, or a mistake in any other respect; and may, upon like terms, enlarge the time for answer or demurrer. The court may likewise, in its discretion, after notice to the adverse party, allow, upon any terms as may be just, an amendment to any pleading or proceeding in other particulars; and may upon like terms allow an answer to be made after the time limited by this code.” According to the state, this section means that after the trial court sustained the demurrer and ordered Harlan to amend within 10 days, it was powerless to alter the filing deadline without a noticed motion by Harlan.
The state is mistaken. Code of Civil Procedure section 472a, subdivision (c), provides that “[w]hen a demurrer is sustained, the court may grant leave to amend the pleading upon any terms as may be just and shall fix the time within which the amendment or amended pleading shall be filed.” Where, as here, leave to amend is granted because the court sustained defendant’s demurrer, defendant can hardly claim to have been deprived of the “notice” mentioned in Code of Civil Procedure section 473, subdivision (a)(1). It makes no difference that the state did not receive additional notice before the court accepted the filing several days late, effectively fixing a new time for amendment. The court could have given Harlan 20 days to amend instead of 10 in the first place, and the state would have had no grounds to object. While the court had discretion to require a noticed motion before permitting Harlan to file the second amended complaint late, we think it also had discretion under these circumstances to accept the filing without a noticed motion.
Code of Civil Procedure section 581, subdivision (f)(2) (on which the state’s motion to dismiss was based), also undermines the state’s view that a *874noticed motion was required before the court could extend Harlan’s deadline. That statute provides: “The court may dismiss the complaint . . . when: [][] . . . [f] . . . after a demurrer to the complaint is sustained with leave to amend, the plaintiff fails to amend it within the time allowed by the court and either party moves for dismissal.” (Italics added.) The state’s argument is, in effect, that upon the state’s motion the court must dismiss if Harlan fails to amend within the time allowed by the court and never moves for leave to file late. But section 581, subdivision (f)(2), places the decision within the court’s discretion.
The state relies on Leader v. Health Industries of America, Inc. (2001) 89 Cal.App.4th 603 [107 Cal.Rptr.2d 489], in which the trial court sustained the defendant’s demurrer with leave to amend within 20 days. The plaintiffs failed to file an amended complaint on time and did not attempt to file one until arriving at a status conference with a proposed amended complaint in hand, more than a month after the court-ordered deadline. {Id. at p. 608.) The court directed the plaintiffs to file a motion for leave to file the amended complaint. Then it denied that motion and granted the defendant’s motion to strike and to dismiss. {Id. at pp. 610-611.) In affirming, the Court of Appeal stated that “to obtain the court’s permission [to file the amended complaint after the court-ordered deadline], plaintiffs were required to file a noticed motion for leave.” {Id. at p. 613.)
We decline to apply this proposition. First, the Leader court did not need to do so since it also held that the trial court acted within its discretion under Code of Civil Procedure section 581, subdivision (f)(2), in granting the defendant’s motion to dismiss for failure to file the amendment in time. More importantly, the point is not supported by the authorities the Leader court cited for it: Loser v. E. R. Bacon Co. (1962) 201 Cal.App.2d 387 [20 Cal.Rptr. 221] and Code of Civil Procedure section 473, subdivision (a)(1). (See Leader v. Health Industries of America, Inc., supra, 89 Cal.App. 4th at p. 613.) In Loser, the plaintiff filed a first amended complaint and then, although there was no demurrer and the defendant had already answered, filed a second amended complaint without first moving the court for leave to do so. The trial court granted the defendant’s motion to strike without prejudice to the plaintiff’s right to file a motion for leave to amend. (Loser v. E. R. Bacon Co., supra, 201 Cal.App.2d at p. 389.) The Court of Appeal affirmed, holding that a plaintiff has no right to amend as a matter of course after the defendant answers and must request leave. (Id. at pp. 389-390.) This holding has no bearing on the situation where, as here and in Leader, the trial court has already granted leave to amend in an order sustaining a demurrer.
Similarly, although Code of Civil Procedure section 473, subdivision (a)(1), gives the court discretion to permit amendment of any pleading *875only after notice to the adverse party, the adverse party has already received notice when the court sustains a demurrer with leave to amend pursuant to Code of Civil Procedure section 472a, subdivision (a). In sum, Leader goes beyond the statutory requirements to the extent it holds that where the court has properly sustained a demurrer, granted leave to amend, and fixed a time for filing the amended complaint, it has no discretion subsequently to extend the time without a noticed motion by the plaintiff.
The state also relies on Remainders, Inc. v. Superior Court (1961) 192 Cal.App.2d 411 [13 Cal.Rptr. 221]. That case is not on point. It involves a trial court’s order setting aside a defendant’s default that had been entered by the clerk. The default was entered the day after the defendant’s answer was due, and the defendant filed an answer the same day. The plaintiff filed a motion to strike the answer, but the court denied it and set aside the default on its own motion. (Id. at p. 412.) The Court of Appeal granted a writ of mandate, holding that relief from a properly entered default can be granted only upon an application by the defendant. (Id. at pp. 412-413.) This holding was based on Code of Civil Procedure section 473, subdivision (b), which provides that “[t]he court may, upon any terms as may be just, relieve a party or his or her legal representative from a judgment, dismissal, order, or other proceeding taken against him or her through his or her mistake, inadvertence, surprise, or excusable neglect. Application for this relief shall be accompanied by a copy of the answer or other pleading proposed to be filed therein . . . .”
This provision does not apply here. The state characterizes Harlan’s late filing as a default, but the fact is that no “judgment, dismissal, order or other proceedings” had been taken against Harlan, so there was nothing from which to relieve it.3
Finally, the state’s reliance on Lincoln Holding Corp. v. Union Indem. Co. (1933) 129 Cal.App. 399, 401-402 [18 P.2d 744] is also misplaced. That case involved a conditional denial of a motion for judgment on the pleadings that, by its terms, became an order granting the motion when the plaintiff failed to file an amended complaint by a stated date. The Court of Appeal held that *876after the plaintiff failed to file in time and the order became one that granted judgment, the trial court could not grant relief from the order except upon a noticed motion. There was no such conditional order in this case and therefore nothing from which Harlan needed relief.
H.-IV.*
DISPOSITION
The judgment is affirmed. Each party shall bear its own costs.
Dibiaso, Acting P. J., and Dawson, J., concurred.
See footnote, ante, page 868.
That fact also defeats the state’s argument that because relief from a default must be requested by motion within six months after the default is taken (Code Civ. Proc., § 473, subd. (b)), the court lacked jurisdiction to deny the state’s motion in limine, which was filed more than six months after the expiration of the court-ordered filing deadline. The state’s reasoning is that the court lost jurisdiction because six months passed from a default without any request by Harlan for leave to file the second amended complaint late. But there was no default in the relevant sense. Code of Civil Procedure section 473, subdivision (b), concerns relief from “a judgment, dismissal, order, or other proceeding taken against” a party. The court took no action like this against Harlan.
See footnote, ante, page 868.