EXHIBIT 4 CONSENT, WAIVER AND SECOND AMENDMENT TO SECOND AMENDED AND RESTATED CREDIT AGREEMENT This Consent, Waiver and Second Amendment to the Second Amended and Restated Credit Agreement is dated as of January 12, 1999 ("Agreement"), and is by and among B&G FOODS, INC., a Delaware corporation ("Borrower"), B&G FOODS HOLDINGS CORP., a Delaware corporation ("Holdings"), each of the Subsidiaries party hereto, as guarantors (collectively, the "Subsidiary Guarantors"), the financial institutions parties hereto (the "Lenders") and HELLER FINANCIAL, INC., a Delaware corporation, Agent for the other Lenders party thereto and as a Lender ("Agent"). WITNESSETH: WHEREAS, Borrower, Lenders and Agent are parties to that certain Second Amended and Restated Credit Agreement dated as of August 11, 1997 (as amended from time to time, the "Credit Agreement") (capitalized terms not otherwise defined herein shall have the definitions provided therefor in the Credit Agreement) and to certain other documents executed in connection with the Credit Agreement; and WHEREAS, Holdings is a party to that certain Holdings Guaranty dated as of December 27, 1996 in favor of Agent, for the benefit of Agent and Lenders (as from time to time amended, restated, supplemented, modified or reaffirmed, the "Holdings Guaranty"), pursuant to which Holdings has guaranteed the Obligations of Borrower under the Credit Agreement and the other Loan Documents; and WHEREAS, each of the Subsidiary Guarantors (other than Trappey's, MGF and UN) is a party to that certain Second Amended and Restated Subsidiary Guaranty dated as of August 11, 1997 in favor of Agent, for the benefit of Agent and Lenders (as from time to time amended, restated, supplemented, modified or reaffirmed, the "Existing Subsidiary Guaranty"), pursuant to which each such Subsidiary Guarantor has guaranteed the Obligations of Borrower under the Credit Agreement and the other Loan Documents; and WHEREAS, Trappey's is a party to that certain Subsidiary Guaranty dated as of August 15, 1997 in favor of Agent, for the benefit of Agent and Lenders (as from time to time amended, restated, supplemented, modified or reaffirmed, the "Trappey's Subsidiary Guaranty"), pursuant to which such Subsidiary Guarantor has guaranteed the Obligations of Borrower under the Credit Agreement and the other Loan Documents; and WHEREAS, each of MGF and UN is a party to a Subsidiary Guaranty dated as of July 17, 1998 in favor of Agent, for the benefit of Agent and Lenders (each, as from time to time amended, restated, supplemented, modified or reaffirmed, a "Maple Grove Subsidiary Guaranty"; the Trappey's Subsidiary Guaranty and each Maple Grove Subsidiary Guaranty may be individually referred to herein as an "Additional Subsidiary Guaranty" and collectively as the "Additional Subsidiary Guaranties"), pursuant to which each such Subsidiary Guarantor has guaranteed the Obligations of Borrower under the Credit Agreement and the other Loan Documents; and WHEREAS, the parties wish to amend the Credit Agreement as provided herein; and WHEREAS, Holdings wishes to reaffirm its Obligations under the Holdings Guaranty; and WHEREAS, each of the Subsidiary Guarantors wishes to reaffirm its Obligations under the Existing Subsidiary Guaranty or the Additional Subsidiary Guaranty to which it is a party, as applicable; NOW, THEREFORE, the parties agree as follows: 1. Amendments to the Credit Agreement. ---------------------------------- A. Amendment to Subsection 1.1(B). ------------------------------ From and after the date hereof (the "Second Amendment Effective Date"), subsection 1.1(B) of the Credit Agreement is amended by deleting the first sentence of such subsection and inserting the following in substitution therefor: Subject to the satisfaction of the terms and conditions set forth herein and in reliance upon the representations and warranties of Borrower set forth herein, each Lender agrees, severally and not jointly, to lend to Borrower from time to time from the Original Closing Date to the Expiry Date its Pro Rata Share of the loans requested by Borrower to be made by Lenders under this subsection 1.1(B), up to an aggregate maximum for all Lenders of $60,000,000 (as the same may be reduced from time to time hereunder, the "Revolving Loan Commitment"; the Revolving Loan Commitment of each Lender as of the Second Amendment Effective Date is as set forth on the signature pages to the Second Amendment). B. Amendments to Subsection 1.2(A). ------------------------------- (1) From and after the Second Amendment Effective Date, subsection 1.2(A)(1) of the Credit Agreement is amended by deleting the first sentence of such subsection and inserting the following in substitution therefor: the Revolving Loans and all other Obligations shall bear interest at a per annum rate equal to the sum of the Base Rate plus the Base Rate Margin. -2- (2) From and after the Second Amendment Effective Date, subsection 1.2(A)(2) of the Credit Agreement is amended by deleting the first sentence of such subsection and inserting the following in substitution therefor: the Revolving Loans and all other Obligations shall bear interest at a per annum rate equal to the sum of the LIBOR plus the LIBOR Margin. C. Amendment to Subsection 4.1. --------------------------- From and after the Second Amendment Effective Date, subsection 4.1 of the Credit Agreement hereby is amended by deleting it and substituting therefor as follows: 4.1 Capital Expenditure Limits. The aggregate amount of all Capital Expenditures of Borrower and its Subsidiaries in any fiscal year of Borrower will not exceed the amount set forth below for such fiscal year. Fiscal Year Maximum Capital Expenditures ----------- ---------------------------- 1999 and each fiscal year thereafter $4,000,000 "Capital Expenditures" will be calculated as illustrated on Exhibit 4.6(C). D. Amendment to Subsection 7.2. --------------------------- From and after the Second Amendment Effective Date, subsection 7.2 of the Credit Agreement hereby is amended by inserting a new subsection 7.2(E) as follows: (E) If Availability during any period of fifteen (15) consecutive Business Days is less than $2,000,000, BRS shall have made an additional cash contribution to the common equity of Borrower of not less than $5,000,000, which contribution shall have been made no later than the tenth (10th) Business Day following the last day of such fifteen (15) Business Day period. E. Amendments to Section 10.1. -------------------------- (1) From and after the Second Amendment Effective Date, subsection 10.1 of the Credit Agreement is hereby amended by deleting the defined term "Commitment" in its entirety and inserting the following in substitution therefor: "Commitment" means, with respect to any Lender as of any date of determination, the amount of such Lender's commitment to make Revolving -3- Loans, as set forth on the signature page of this Agreement opposite such Lender's signature, on the signature page of any amendment to this Agreement opposite such Lender's signature, or in a Lender Addition Agreement, if any, executed by such Lender, whichever is most recent as of such date of determination. (2) From and after the Second Amendment Effective Date, subsection 10.1 of the Credit Agreement is hereby amended by inserting the following new defined term in proper alphabetical order: "Adjustment Date" means February 1, May 1, August 1 and November 1 of each year. "Availability" means, as of any date of determination, the Revolving Loan Commitment less the sum of (a) the outstanding principal balance of the Revolving Loan as of such date, plus (b) the outstanding Risk Participation Liability as of such date. "Base Rate Margin" shall mean, (i) as of the Second Amendment Effective Date, 1.00% per annum, and (ii) thereafter, as of each Adjustment Date, commencing with August 1, 1999, the Base Rate Margin shall be adjusted, if necessary, to the applicable percent per annum set forth in the pricing table below opposite the Senior Indebtedness to EBITDA Ratio calculated for the relevant Calculation Period. PRICING TABLE ------------- Senior Indebtedness to EBITDA Ratio Base Rate Margin ----------------------------------- ---------------- Less than 1.0 to 1.0 0.75% Equal to or greater than 1.0 to 1.0, but less than 2.0 to 1.0 1.00% Equal to or greater than 2.0 to 1.0 1.50% If Borrower shall fail to deliver a Compliance Certificate by the date required pursuant to subsection 4.6(C), effective as of the tenth Business Day following the date on which such Compliance Certificate was due, the Base Rate Margin shall be conclusively presumed to equal the highest Base Rate Margin specified in the pricing table set forth above until the date of delivery of the Compliance Certificate "Calculation Period" means, as of any Adjustment Date, the trailing twelve month period ending on the last day of the most recently completed calendar -4- quarter prior to such Adjustment Date. "LIBOR Margin" shall mean, (i) as of the Second Amendment Effective Date, 2.50% per annum, and (ii) thereafter, as of each Adjustment Date, commencing with August 1, 1999, the LIBOR Margin shall be adjusted, if necessary, to the applicable percent per annum set forth in the pricing table below opposite the Senior Indebtedness to EBITDA Ratio calculated for the relevant Calculation Period. PRICING TABLE ------------- Senior Indebtedness to EBITDA Ratio LIBOR Margin ----------------------------------- ------------ Less than 1.0 to 1.0 2.25% Equal to or greater than 1.0 to 1.0, but less than 2.0 to 1.0 2.50% Equal to or greater than 2.0 to 1.0 3.00% If Borrower shall fail to deliver a Compliance Certificate by the date required pursuant to subsection 4.6(C), effective as of the tenth Business Day following the date on which such Compliance Certificate was due, the LIBOR Margin shall be conclusively presumed to equal the highest LIBOR Margin specified in the pricing table set forth above until the date of delivery of the Compliance Certificate "Polaner Acquisition" means the acquisition by Roseland Distribution from the Polaner Sellers of substantially all of the assets of the Polaner Sellers related to the "Polaner" brand and any other brands described in the Polaner Acquisition Agreement, and all associated products, pursuant to the terms and conditions of the Polaner Acquisition Agreement. "Polaner Acquisition Agreement" means the Asset Purchase Agreement to be dated on or about the Second Amendment Effective Date, by and among Roseland Distribution and the Polaner Sellers, and the other documents, instruments and agreements executed and delivered pursuant thereto or in connection therewith. "Polaner Sellers" means, collectively, International Home Foods, Inc., a Delaware corporation and M. Polaner, Inc., a Delaware corporation. "Second Amendment" means that certain Consent, Waiver and Second Amendment to Credit Agreement dated as of the Second Amendment Effective Date among Borrower, Holdings, each Subsidiary Guarantor, Agent and Lenders. -5- "Second Amendment Effective Date" means January 12, 1999. "Senior Indebtedness to EBITDA Ratio" means, for any Calculation Period, the ratio of (i) Borrower's Total Indebtedness (calculated as illustrated on Exhibit 4.6(C), but less Borrower's Subordinated Indebtedness), to (ii) EBITDA (calculated as illustrated on Exhibit 4.6(C)) for the twelve (12) month period ending on the last day of such month. 2. Consent and Waiver. Subsection 3.18 of the Credit Agreement prohibits the Loan Parties from acquiring by purchase or otherwise all or any substantial part of the business or assets or capital stock of any other Person unless such acquisition constitutes a Permitted Acquisition or such acquisition is consented to by the Requisite Lenders. Borrower has requested that Agent and the Lenders consent to the Polaner Acquisition by its Subsidiary, Roseland Distribution and to the execution and delivery of the guaranty of Borrower in connection therewith. The Polaner Acquisition does not satisfy the conditions outlined in subsection 3.18(ii) of the Credit Agreement for a Permitted Acquisition. Agent and Requisite Lenders hereby consent to the consummation of the Polaner Acquisition and to the execution and delivery of the guaranty (in form and substance reasonably satisfactory to Agent) of Borrower in connection therewith; provided, however, that: (A) the Polaner Acquisition is completed no later than February 28, 1999, with no material deviations from the terms and conditions set forth in the Polaner Acquisition Agreement, (B) the most recent financial statements of the Polaner Sellers and all other appraisals, accounting reviews, material due diligence reports, projections, certificates and other materials and information required to be delivered pursuant to subsection 3.18 of the Credit Agreement in connection with the Polaner Acquisition shall have been provided to Agent and shall be satisfactory to Agent (and Agent acknowledges that all such materials have been delivered and are satisfactory as of the Second Amendment Effective Date, provided that Borrower shall continue to remain obligated to deliver such materials to Agent prior to the closing of the Polaner Acquisition in the event Borrower discovers any material new information or material changes in existing information in the course of its due diligence regarding the Polaner Acquisition), and, without duplication of the foregoing, the conditions precedent to Permitted Acquisitions set forth in subsection 3.18 (other than subsection 3.18(n)) of the Credit Agreement shall have been satisfied in connection with the Polaner Acquisition, (C) contemporaneously with the consummation of the Polaner Acquisition, (i) if -6- necessary, Roseland Distribution shall execute and deliver such UCC financing statements and such other Security Documents as the Agent may request in order to grant to Agent, for the benefit of Agent and Lenders, a first priority perfected security interest in and to substantially all of the assets acquired pursuant to the Polaner Acquisition; and (ii) all Liens on any of the assets acquired pursuant to the Polaner Acquisition securing Indebtedness of the Polaner Sellers or otherwise described on such schedule shall be released and terminated in full or termination statements with respect thereto shall be executed and delivered and made available for filing on the closing date of the Polaner Acquisition; and (D) the Acquisition Agreement shall have been collaterally assigned to Agent, for the benefit of Agent and Lenders, pursuant to a Collateral Assignment of Representations, Warranties, Covenants, Indemnities and Rights reasonably satisfactory to Agent. Nothing in this subsection 2 shall be construed by Borrower to be a waiver of any other term or condition of the Credit Agreement or a consent to any other transaction. 3. Representations and Warranties. To induce Agent and Lenders to enter into this Agreement, Borrower, Holdings and each Subsidiary Guarantor represents and warrants to Agent on behalf of the Lenders that the execution, delivery and performance by Borrower, Holdings and each Subsidiary Guarantor of this Agreement are within their respective corporate powers, have been duly authorized by all necessary corporate action and do not and will not contravene or conflict with any provision of law applicable to Borrower, Holdings or any Subsidiary Guarantor, the Certificate of Incorporation or Bylaws of Borrower, Holdings or any Subsidiary Guarantor, or any order, judgment or decree of any court or other agency of government or any contractual obligation binding upon Borrower, Holdings or any Subsidiary Guarantor; and the Credit Agreement and the other Loan Documents, as amended or reaffirmed as of the date hereof, are the legal, valid and binding obligation of each of Borrower, Holdings and each Subsidiary Guarantor, enforceable against each such Person in accordance with its terms. 4. Conditions. The effectiveness of the amendments stated in this Agreement is subject to each of the following conditions precedent or, in the case of clause (H) below, conditions subsequent: (A) Execution of Agreement. This Agreement shall have been duly executed and delivered by Borrower, Holdings, each Subsidiary Guarantor listed on the signature pages hereof and by the Requisite Lenders. (B) Fee Letters; Payment of Fees. Borrower shall have executed and delivered fee letters to (a) the Lenders executing this Agreement which have purchased a portion of the $10,000,000 increase in the Revolving Loan Commitment provided for hereunder, setting forth -7- Borrower's agreement to pay certain fees to the Lenders in consideration for such Commitment increase and the consents set forth herein, (b) the Lenders executing this Agreement which have consented to the transactions set forth herein but which have not purchased a portion of such Commitment increase, setting forth Borrower's agreement to pay certain fees to the Lenders in consideration for such consent, and (c) Agent, setting forth Borrower's agreement to pay certain fees to Agent, and Borrower shall have paid or caused to be paid to Agent and/or Lenders any such fees payable on the Second Amendment Effective Date pursuant to any such fee letters. (C) Notes. Borrower shall have executed and delivered to each applicable Lender new notes evidencing the Revolving Loan Commitment of such Lender after giving effect to the Commitment increase effected hereby. (D) Side Letter. BRS shall have executed and delivered a letter agreement setting forth its agreement that, if Availability during any period of fifteen (15) consecutive Business Days is less than $2,000,000, BRS shall make an additional cash contribution to the common equity of Borrower of not less than $5,000,000, which contribution shall be made no later than the tenth (10th) Business Day following the last day of such fifteen (15) Business Day period. (E) No Default. No Default or Event of Default under the Credit Agreement, as amended hereby, shall have occurred and be continuing. (F) Warranties and Representations. The warranties and representations of the Loan Parties contained in this Agreement, the Credit Agreement, as amended hereby, and the other Loan Documents, shall be true and correct as of the effective date hereof, with the same effect as though made on such date. (G) Consent of Holders of Subordinated Indebtedness. To the extent consents, waivers or amendments are required based on the amendment or consent provided for in this Agreement or the Polaner Acquisition, Borrower shall have provided Agent with copies of all documents executed by the Borrower, Holdings or the holders of Subordinated Indebtedness, which documents shall be in form and substance satisfactory to Agent. (H) Conditions Subsequent. (1) As promptly as practicable following the Second Amendment Effective Date, Borrower shall execute and deliver such modifications to the existing mortgages or deeds of trust in favor of Agent as may be necessary to reflect the increase in the Revolving Loan Commitment effected pursuant to this Agreement. (2) Upon consummation of the Polaner Acquisition, Borrower shall have delivered or caused to be delivered all documents and instruments necessary or appropriate to evidence that Agent, on behalf of the Lenders, shall, upon consummation of the Polaner Acquisition, have a first priority perfected security interest in and to substantially all of the assets acquired by Roseland Distribution pursuant to the Polaner Acquisition and, without duplication of the foregoing, each -8- of the other conditions set forth in subsection 2 hereof shall have been met or satisfied. 5. Miscellaneous. ------------- (A) Captions. Section captions used in this Agreement are for convenience only, and shall not affect the construction of this Agreement. (B) Governing Law. This Agreement shall be a contract made under and governed by the laws of the State of New York, without regard to conflict of laws principles. Whenever possible each provision of this Agreement shall be interpreted in such manner as to be effective and valid under applicable law, but if any provision of this Agreement shall be prohibited by or invalid under such law, such provision shall be ineffective to the extent of such prohibition or invalidity, without invalidating the remainder of such provision or the remaining provisions of this Agreement. (C) Counterparts. This Agreement may be executed in any number of counterparts, and each such counterpart shall be deemed to be an original, but all such counterparts shall together constitute but one and the same Agreement. (D) Successors and Assigns. This Agreement shall be binding upon Borrower, Holdings, each Subsidiary Guarantor, Agent and Lenders and their respective successors and assigns, and shall inure to the sole benefit of each of Borrower, Holdings, each Subsidiary Guarantor, Agent and Lenders and the successors and assigns of each of Borrower, Holdings, each Subsidiary Guarantor, Agent and Lenders. (E) References. Any reference to the Credit Agreement contained in any notice, request, certificate, or other document executed concurrently with or after the execution and delivery of this Agreement shall be deemed to include this Agreement unless the context shall otherwise require. (F) Continued Effectiveness; Reaffirmation. Notwithstanding anything contained herein, the terms of this Agreement are not intended to and do not serve to effect a novation as to the Credit Agreement. The parties hereto expressly do not intend to extinguish the Credit Agreement. Instead, it is the express intention of the parties hereto to reaffirm the indebtedness created under the Credit Agreement which is evidenced by the Notes and secured by the Collateral. The Credit Agreement as amended hereby and each of the other Loan Documents remains in full force and effect. Holdings hereby reaffirms its continuing liability as a guarantor for the Obligations of Borrower under the Credit Agreement pursuant to the Holdings Guaranty and acknowledges and agrees that the Liens on its Collateral granted under the Loan Documents are continuing and are hereby reaffirmed. Each of the Subsidiary Guarantors hereby reaffirms its continuing liability as a guarantor for the Obligations of Borrower under the Credit Agreement pursuant to the Existing Subsidiary Guaranty and the Additional Subsidiary Guaranty, as applicable, and acknowledges and agrees that the Liens on its Collateral granted under the Loan Documents are continuing and are hereby reaffirmed. -9- (signatures pages follow) -10- IN WITNESS WHEREOF, each of the undersigned has caused this Agreement to be duly executed and delivered by its duly authorized officer as of the day and year first above written. B&G FOODS, INC., as Borrower By: /s/David Wenner ------------------------------- Title: President ---------------------------- S-1 Commitment to make Revolving HELLER FINANCIAL, INC., as Agent and a Loans Lender $11,000,000 Percentage of Revolving By: /s/ Loan Commitment: ---------------------------------- 18.33300% Title: ------------------------------- S-2 Commitment to make Revolving Loans BANKBOSTON, N.A. $9,000,000 as a Lender Percentage of Revolving Loan Commitment: By: /s/ 15.00000% ---------------------------------- Title: Managing Director ------------------------------- S-3 Commitment to make Revolving Loans BANK AUSTRIA CREDITANSTALT CORPORATE $10,000,000 FINANCE, INC., as a Lender Percentage of Revolving Loan Commitment: By: /s/Clifford L. Weiss 16.66675% ---------------------------------- Title: Vice President ------------------------------- By: /s/Catherine K. MacDonald ---------------------------------- Title: Vice President ------------------------------- S-4 Commitment to make Revolving Loans FIRST SOURCE FINANCIAL LLP, by $10,000,000 FIRST SOURCE FINANCIAL INC., its Percentage of Revolving agent/manager, as a Lender Loan Commitment: 16.66675% By: /s/Kathi J. Inorio ---------------------------------- Title: Vice President ------------------------------- S-5 Commitment to make Revolving Loans IBJ WHITEHALL BANK & TRUST COMPANY, $10,000,000 as a Lender Percentage of Revolving Loan Commitment: By: /s/Mark H. Minter 16.66675% ---------------------------------- Title: Managing Director ------------------------------- S-6 Commitment to make Revolving Loans THE BANK OF NEW YORK, as a Lender $10,000,000 Percentage of Revolving By: /s/Frank S. Bridges Loan Commitment: ------------------------------- 16.66675% Title: Vice President ---------------------------- By: ------------------------------- Title: ----------------------------- S-7 Guarantors: B&G FOODS HOLDINGS CORP. By: /s/David Wenner ------------------------------- Title: President ----------------------------- BGH HOLDINGS, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- ROSELAND DISTRIBUTION COMPANY, formerly known as B&G FOODS, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- BLOCH & GUGGENHEIMER, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- S-8 RWBV ACQUISITION CORP. By: /s/David Wenner ------------------------------- Title: President ----------------------------- BURNS & RICKER, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- TRAPPEY'S FINE FOODS, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- MAPLE GROVE FARMS OF VERMONT, INC. By: /s/David Wenner ------------------------------- Title: President ----------------------------- S-9