
77 Cal.App.3d 619 (1978)
143 Cal. Rptr. 799
LONNIE GRANT WOOLETT, Plaintiff and Appellant,
v.
AMERICAN EMPLOYERS INSURANCE COMPANY, Defendant and Respondent.
Docket No. 40071.
Court of Appeals of California, First District, Division Two.
February 16, 1978.
*621 COUNSEL
Popko, Cornblum, Miller & Eddy, Bruce I. Cornblum and Herbert Resner for Plaintiff and Appellant.
Ericksen, Lynch, Mackenroth, Arbuthnot & Brennan, Preston N. Ericksen and John M. Bayne, Jr., for Defendant and Respondent.
OPINION
ROUSE, J.
Plaintiff, Lonnie Woolett, appeals from a judgment entered in favor of defendant, American Employers Insurance Company, after the trial court sustained general demurrers to both counts of the complaint and plaintiff declined to amend within the time allowed by the court.
Plaintiff's complaint, which contained two counts, was filed on March 3, 1976. The first count alleged that plaintiff was involved in an automobile accident on May 31, 1966; that later he brought suit against Oscar Crawford and John Penrose, and that, on April 20, 1970, a joint and several judgment in the amount of $633,000 was entered in favor of plaintiff and against Crawford and Penrose; that at the time of the *622 accident, Crawford and Penrose were covered by an automobile liability insurance policy issued by defendant; that plaintiff had demanded that defendant pay the amount of the judgment which he had recovered against Crawford and Penrose, but that defendant refused to do so; that plaintiff was a third party beneficiary of the policy issued to Crawford and Penrose and was entitled to bring suit directly against defendant pursuant to section 11580 of the Insurance Code.
The second count of the complaint alleged that both before and after plaintiff recovered the judgment against Crawford and Penrose, he had offered to settle the case within the limits of defendant's insurance policy, but that defendant had refused such offers of settlement and, in so doing, had acted in bad faith; that defendant's refusal of these settlement offers had subjected Crawford to a judgment substantially in excess of the policy limits; that on February 25, 1976, plaintiff had obtained from Crawford a written assignment of all the rights which Crawford had against defendant for its refusal to settle the case within the policy limits.
Defendant demurred to both counts of the complaint, asserting that they were barred by the applicable statute of limitations, viz., section 337, subdivision 1, of the Code of Civil Procedure, and that the second count was also barred by the doctrine of res judicata, since Crawford's rights against defendant had been finally adjudicated in an action brought in New Mexico.
The trial court sustained the demurrer with leave to amend and when plaintiff declined to amend, rendered a judgment for defendant.
The first count of the complaint purported to state a cause of action based upon section 11580 of the Insurance Code. Subdivision (b)(2) of that statute provides, in part, that every liability insurance policy issued or delivered in this state must contain and shall be construed to contain "A provision that whenever judgment is secured against the insured ... in an action based upon bodily injury ... or property damage, then an action may be brought against the insurer on the policy and subject to its terms and limitations, by such judgment creditor to recover on the judgment."
Section 337, subdivision 1, of the Code of Civil Procedure, provides that "An action upon any contract, obligation or liability founded upon an instrument in writing" must be commenced within four years. Since *623 section 11580 of the Insurance Code authorizes an action against the insurer "on the policy and subject to its terms and limitations," it would appear that the cause of action alleged in the first count of plaintiff's complaint was subject to the four-year period of limitations. It is perhaps because the language of section 11580 is so free from ambiguity in this regard that there is virtually no case law dealing with the question of what statute of limitations applies. Malmgren v. Southwestern Auto. Ins. Co. (1932) 126 Cal. App. 135, 139 [14 P.2d 351], a case involving a suit brought under the predecessor statute to section 11580, appears to be the only case directly holding that the four-year statute of limitations applies. Notwithstanding its vintage, it appears that the Malmgren case was correctly decided. It was cited with approval in Zander v. Texaco, Inc. (1968) 259 Cal. App.2d 793, 807 [66 Cal. Rptr. 561].
Plaintiff's contention that a different and longer period of limitations applies is based upon two cases: Olds v. General Acc. Fire etc. Corp. (1945) 67 Cal. App.2d 812 [155 P.2d 676], and Gay v. Straube (1966) 245 Cal. App.2d 683 [54 Cal. Rptr. 293]. We conclude that neither case provides support for his position. The Olds case involved a situation where the plaintiff recovered a judgment against the insured and commenced suit against the insurer (under the predecessor statute to § 11580) a little over a year after the judgment against the insured became final. The plaintiff recovered judgment against the insurer, which then appealed, contending that the plaintiff was bound by a provision in the insurance policy which required that an action to recover for any loss under the policy be brought within one year after the right of action had accrued. The appellate court held that this provision was inapplicable to the plaintiff and further held that since the plaintiff had commenced his suit against the insurer slightly over a year after his judgment against the insured had become final, the plaintiff's suit was timely brought regardless of which statute of limitations was deemed applicable. The court stated, "If a statutory liability was thus created the period of limitations would be three years (Code Civ. Proc., § 338); if the action is upon an agreement in writing, on the theory that the injured person [the plaintiff] is a third party beneficiary, the period would be four years (Code Civ. Proc., § 337); while if the action is upon a judgment, the period would be five years (Code Civ. Proc., § 336)." (Pp. 819-820.) The court did not undertake to determine which of the three periods of limitations applied, since such determination was obviously unnecessary to its decision; hence, the case furnishes no authority for plaintiff's contention that the action must be deemed one on a judgment rather than on an agreement in writing. In fact, it seems to us that the *624 Olds case tends to support defendant's position, since the court indicated that the four-year statute of limitations would apply if the plaintiff were deemed to be suing in the capacity of a third party beneficiary of the insurance policy. In Murphy v. Allstate Ins. Co. (1976) 17 Cal.3d 937, 943 [132 Cal. Rptr. 424, 553 P.2d 584], the California Supreme Court recently so characterized an action brought under section 11580, subdivision (b)(2), of the Insurance Code, stating that that provision "makes the judgment creditor a third party beneficiary of the insurance contract between the insurer and the insured."
The second case cited by plaintiff, Gay v. Straube, supra, 245 Cal. App.2d 683, is also inapposite. The court there held that two legatees who brought suit against an executrix to enforce a decree of distribution were suing upon the decree, hence were subject to the statute of limitations applicable to actions upon a judgment or decree. We agree with defendant that there is no real similarity between an action based upon a probate decree of distribution which finally established the rights of the legatees and the executrix, and an action brought under section 11580, subdivision (b)(2), of the Insurance Code, "on the policy and subject to its terms and limitations...."
(1) We conclude that the cause of action alleged in the first count of plaintiff's complaint was governed by the four-year statute of limitations prescribed by section 337, subdivision 1, of the Code of Civil Procedure. It follows, therefore, that the trial court was correct in sustaining defendant's demurrer to that count. A cause of action predicated upon section 11580, subdivision (b)(2), of the Insurance Code, arises when a final judgment against the insured has been entered. (Zander v. Texaco, Inc., supra, 259 Cal. App.2d at p. 807.) Plaintiff's judgment against Crawford and Penrose was entered on April 20, 1970, and it became final, at the very latest, 180 days thereafter. (See rule 2(a), Cal. Rules of Court.) Thus, plaintiff's cause of action under section 11580, subdivision (b)(2), of the Insurance Code, arose in October 1970, and the applicable four-year statute of limitations began to run at that time. Since the complaint in the instant action was not filed until March 1976, it was barred by section 337, subdivision 1, of the Code of Civil Procedure.
(2) In the second count of his complaint, plaintiff, as the assignee of Crawford, sought to recover damages for defendant's breach of the implied covenant to treat Crawford, its insured, with good faith and to settle within the policy limits where there was a substantial likelihood that a judgment in excess of those limits would otherwise be recovered *625 against the insured. In Murphy v. Allstate Ins. Co., supra, 17 Cal.3d 937, the California Supreme Court held that the insurer's duty to settle is intended to benefit the insured only, and that an injured person who recovers judgment against the insured may not bring suit against the insurer for breach of the covenant to settle unless he has obtained an assignment of such cause of action from the insured. Thus, plaintiff's right to recover for defendant's breach of the implied covenant to settle, in this instance, was entirely dependent upon the existence of an assignment from Crawford. As Crawford's assignee, plaintiff stands in Crawford's shoes and is subject to any defenses which defendant had against Crawford prior to notice of the assignment. (Civ. Code, § 1459; Code Civ. Proc., § 368; Berrington v. Williams (1966) 244 Cal. App.2d 130, 135-136 [52 Cal. Rptr. 772]; 1 Witkin, Summary of Cal. Law (8th ed. 1973) Contracts, § 751, p. 628.)
In Comunale v. Traders & General Ins. Co. (1958) 50 Cal.2d 654, 662-663 [328 P.2d 198, 68 A.L.R.2d 883], the California Supreme Court held that an insured's cause of action against his insurer for a wrongful refusal to settle arises on the date when the judgment against the insured in the bodily injury action becomes final and that such cause of action is governed by the four-year period of limitations set forth in section 337, subdivision 1, of the Code of Civil Procedure. In this case, the judgment which plaintiff recovered against Crawford became final in October 1970, hence Crawford's cause of action for defendant's wrongful refusal to settle was barred by the statute of limitations after October 1974. It follows, then, that when Crawford purported to assign this cause of action to plaintiff in February 1976, Crawford had nothing of value to assign; therefore, the trial court was correct in sustaining defendant's demurrer to the second count of plaintiff's complaint.
(3) We also agree with defendant that the second count of plaintiff's complaint was subject to demurrer on the ground of res judicata. Here, the trial court took judicial notice of a decision by the Supreme Court of New Mexico, rendered in April 1975, which held that defendant insurer at no time had a duty to indemnify Crawford for his liability to plaintiff; that an employee exclusion in the policy applied, and eliminated coverage for Crawford's liability to plaintiff; and that in the absence of any duty by defendant to indemnify Crawford, defendant likewise had no duty to settle the case within the policy limits.
In Bernhard v. Bank of America (1942) 19 Cal.2d 807, 813 [122 P.2d 892], the California Supreme Court held that the doctrine of res judicata *626 precludes the parties or their privies from relitigating a cause of action which has been finally determined by a court of competent jurisdiction and that the doctrine applies whenever the following three conditions are met: the issue decided in the prior case is identical to the issue in the present action; the prior action resulted in a final judgment on the merits; and the party against whom the doctrine is asserted is a party or in privity with a party to the prior action.
In this instance, those conditions were met: (1) the New Mexico decision determined that defendant had no duty to settle plaintiff's claim with Crawford; (2) the New Mexico judgment is a final judgment determining said issue on its merits; and (3) since plaintiff is suing as Crawford's assignee, he is in privity with Crawford, who was a party to the New Mexico action.
The judgment is affirmed.
Taylor, P.J., and Kane, J., concurred.
Appellant's petition for a hearing by the Supreme Court was denied May 11, 1978. Bird, C.J., Tobriner, J., and Mosk, J., were of the opinion that the petition should be granted.
