EXHIBIT NO. 5.1 E-2 LOCKE PURNELL RAIN HARRELL (A Professional Corporation) 2200 Ross Avenue, Suite 2200 Dallas, Texas 75201 (972) 740-8000 October 4, 1996 Comstock Resources, Inc. 5005 LBJ Freeway, Suite 1000 Dallas, Texas 75244 Re: Registration of 503,557 shares of Common Stock pursuant to a Registration Statement on Form S-3 Gentlemen: We have acted as counsel for Comstock Resources, Inc., a Nevada corporation (the "Company"), in connection with the registration under the Securities Act of 1933, as amended (the "Securities Act"), pursuant to a Registration Statement on Form S-3 (the "Registration Statement"), of 503,557 shares of Common Stock, $.50 par value, of the Company (the "Common Stock") to be issued to certain selling shareholders (the "Selling Shareholders") identified in the Registration Statement upon exercise of certain stock options. We have made such inquiries and examined such documents as we have considered necessary or appropriate for the purpose of giving the opinion hereinafter set forth. We have assumed the genuineness and authenticity of all signatures on all original documents, the authenticity of all documents submitted to us as originals, the conformity to originals of all documents submitted to us as copies and the due authorization, execution, delivery or recordation of all documents where due authorization, execution or recordation are prerequisites to the effectiveness thereof. Based upon the foregoing, having regard for such legal considerations as we deem relevant, we are of the opinion that the 503,557 shares of Common Stock to be issued to the Selling Shareholders, as described in the Registration Statement, have been duly authorized and, assuming receipt of the consideration upon exercise of the options, upon issuance will be legally issued, fully paid and nonassessable. We hereby consent to the filing of this opinion with the Securities and Exchange Commission as an exhibit to the Registration Statement. By so consenting, we do not thereby admit that our firm's consent is required by Section 7 of the Securities Act. Very truly yours, LOCKE PURNELL RAIN HARRELL (A Professional Corporation) By: /s/JACK E. JACOBSEN ----------------------- Jack E. Jacobsen E-3