
912 N.E.2d 756 (2009)
The PEOPLE of the State of Illinois, Plaintiff-Appellee,
v.
Roosevelt T. WELCH, Defendant-Appellant.
No. 3-07-0352.
Appellate Court of Illinois, Third District.
July 14, 2009.
*757 Thomas A. Lilien, Deputy Defender, Office of the State Appellate Defender, Linda A. Johnson, Asst. State Appellate Defender, Elgin, for Roosevelt T. Welch.
Terry A. Mertel, Deputy Director, State's Attorneys Appellate Prosecutor, Ottawa, Jeff Terronez, State's Atty., Rock Island, Gary F. Gnidovec, State's Attorneys Appellate Prosecutor, Ottawa, for the People.
Presiding Justice O'BRIEN delivered the opinion of the court:
Defendant Roosevelt Welch filed a motion for leave to file a successive postconviction petition. Following argument on his motion, the trial court denied it. He appealed. We affirm.

FACTS
In 1995, defendant Roosevelt Welch was convicted by a jury of armed violence, predicated on unlawful possession of a substance containing cocaine, and armed robbery. On April 17, 1995, he was sentenced to two consecutive 30-year terms of imprisonment. In imposing sentence, the trial court stated that it found a substantial change in the nature of the criminal objective and that consecutive sentences were necessary to protect the public. Welch appealed, raising issues of insufficiency of the evidence, improper imposition of consecutive sentences, and ineffective assistance of counsel for failure to oppose joinder of Welch's trial with the trial of his codefendant and for failure to move to sever after antagonistic defenses were *758 raised. This court affirmed Welch's convictions and sentences, holding, in pertinent part, that the trial court did not abuse its discretion in imposing consecutive sentences. People v. Welch, No. 3-95-0404, 289 Ill.App.3d 1147, 239 Ill.Dec. 306, 713 N.E.2d 837 (1997) (unpublished order under Supreme Court Rule 23).
In May 1998, Welch filed a petition for postconviction relief in which he asserted that he was denied effective assistance of counsel and that exculpatory evidence was withheld at trial. The petition was denied after an evidentiary hearing and this court affirmed. People v. Welch, No. 3-99-0086, 315 Ill.App.3d 1233, 268 Ill.Dec. 168, 777 N.E.2d 1091 (2000) (unpublished order under Supreme Court Rule 23). In January 2001, Welch filed a second pro se postconviction petition and a petition for relief from judgment pursuant to section 2-1401 of the Code of Civil Procedure (Civil Code) (735 ILCS 5/2-1401 (West 2000)). In his section 2-1401 petition, Welch argued that the judgment against him was void based on Apprendi principles. See Apprendi v. New Jersey, 530 U.S. 466, 120 S.Ct. 2348, 147 L.Ed.2d 435 (2000). The State moved to dismiss the section 2-1401 petition as untimely. Appointed counsel filed an amended postconviction petition arguing issues of ineffective assistance of counsel, severance, and sentencing. As to the sentencing issue, Welch essentially argued that pursuant to Apprendi, the trial court's findings that his offenses constituted separate courses of conduct and that consecutive sentences were necessary to protect the public were determinations that should have been left to the jury and because the trial court made the findings, his consecutive sentences were void. The trial court denied the petition. On appeal, this court affirmed the trial court, holding that the joinder/severance issue was barred under the cause and prejudice test set forth in People v. Pitsonbarger (205 Ill.2d 444, 464, 275 Ill.Dec. 838, 793 N.E.2d 609, 624 (2002)); Welch did not appeal the sentencing issue. People v. Welch, No. 3-02-0131 (2003) (unpublished order under Supreme Court Rule 23).
In April 2005, Welch filed another pro se petition for relief under section 2-1401 of the Civil Code, asserting that his consecutive sentences were void because the offenses were part of a single course of conduct, that section 5-8-4(a) of the Unified Code of Corrections (Corrections Code) prohibited the imposition of consecutive sentences under the instant facts, and that section 5-8-4(b) is inapplicable where multiple offenses did not arise out of a single course of conduct. 730 ILCS 5/5-8-4 (a), (b) (West 1994). The State filed a motion to dismiss, arguing that the petition was untimely and that Welch failed to establish that the record did not support multiple convictions. The trial court appointed counsel to represent Welch. At an August 2005 hearing, appointed counsel indicated that he was considering that a successive postconviction petition would be the appropriate vehicle for Welch's claims. In light of counsel's statements, the trial court reserved ruling on the State's motion to dismiss. In November 2006, Welch's appointed counsel filed a motion for leave to file a successive postconviction petition pursuant to section 122-1(f) of the Post-Conviction Hearing Act (Act) (725 ILCS 5/122-1(f) (West 2006)). Attached to the motion was a successive postconviction petition which raised the sole issue of whether Welch's trial should have been severed from the trial of his codefendant. Counsel did not file either a Supreme Court Rule 651(c) (134 Ill.2d R. 651(c)) certificate or an amended section 2-1401 petition.
A hearing ensued on Welch's motion for leave to file his successive postconviction petition. Following arguments, the trial *759 court determined that it would read the previous postconviction petitions and the appellate court orders and render a decision. Thereafter, the trial court denied Welch's motion for leave to file, finding that the issue of severance had been previously raised and fully litigated; if not, it was waived; or in the alternative, that Welch could not satisfy the cause and prejudice test required for the filing of successive postconviction petitions. Welch appealed and the Office of the State Appellate Defender was appointed to represent him. The appellate defender filed a motion to withdraw pursuant to Pennsylvania v. Finley, 481 U.S. 551, 107 S.Ct. 1990, 95 L.Ed.2d 539 (1987). This court denied the motion to withdraw and ordered the parties to brief the following two issues:
"(1) Regarding the successive postconviction petition, did the trial court err by considering the State's objection and the arguments of the parties at the first stage of postconviction proceedings?
(2) Did the defendant's appointed trial counsel provide ineffective assistance by failing to pursue the defendant's original section 2-1401 petition? Specifically, counsel should address whether appointed counsel was ineffective by not contending that the sentencing issue raised by the defendant in his original 2-1401 petition may be considered by the trial court despite the untimeliness argument raised in the State's motion to dismiss, and by not zealously advocating the defendant's sentencing issue[.]"

ANALYSIS
The issues we consider on appeal are whether the trial court improperly allowed the State to participate in its examination of Welch's postconviction petition and whether Welch was denied reasonable assistance of counsel by his attorney's failure to pursue Welch's section 2-1401 petition for relief (735 ILCS 5/2-1401 (West 2006)).
We begin with Welch's claim that he was denied reasonable assistance of counsel when his attorney failed to pursue his pro se section 2-1401 petition filed in 2005. In the petition, he alleged that his consecutive sentences were void because his convictions were for two offenses that were part of a single course of conduct and the trial court was without authority to impose consecutive sentences. Welch contends that his attorney's failure to amend, support, or schedule a hearing on the petition constituted unreasonable assistance of counsel. According to Welch, since his consecutive sentences are void, they could be challenged at any time and his petition was not untimely. Because this issue involves questions of law, our review is de novo. People v. Wilson, 228 Ill.2d 35, 40, 319 Ill.Dec. 353, 885 N.E.2d 1033, 1037 (2008).
The procedural history of this case is somewhat atypical. After Welch filed his pro se section 2-1401 petition, counsel was appointed to assist him with the petition. The State filed a motion to dismiss the petition as untimely. Counsel conceded the timeliness issue and indicated in open court that the better vehicle to assert Welch's claims was in a postconviction petition. Counsel thereafter filed a motion for leave to file a successive petition and attached an amended postconviction petition to the motion. On instruction from this court, the parties presented additional arguments on the issue of whether appointed counsel provided deficient representation by failing to contend that the sentencing issue raised by Welch in his section 2-1401 petition may be considered by the trial court despite its untimeliness, as argued by the State in its motion to dismiss, and by failing to zealously advocate Welch's argument that his sentences were void.
*760 Section 2-1401 of the Civil Code provides a mechanism by which final judgments and orders may be challenged more than 30 days after their entry. 735 ILCS 5/2-1401 (West 2006). In considering a section 2-1401 petition, the court must determine whether facts exist that were unknown to the court at the time of trial and would have prevented judgment against the defendant. People v. Hayden, 288 Ill. App.3d 1076, 1078, 229 Ill.Dec. 699, 692 N.E.2d 688, 690 (1997). Similarly, postconviction proceedings are available as means to collaterally attack a criminal conviction. People v. Gandy, 227 Ill.App.3d 112, 142, 169 Ill.Dec. 165, 591 N.E.2d 45, 66 (1992). A postconviction petition is the avenue by which a defendant may bring claims that he was deprived of a constitutional right at trial. Gandy, 227 Ill.App.3d at 142, 169 Ill.Dec. 165, 591 N.E.2d at 66. The Post-Conviction Hearing Act (725 ILCS 5/122-1 et seq. (West 2006)) guarantees a petitioner reasonable assistance of counsel while section 2-1401 does not afford a defendant any specific level of assistance. People v. Pinkonsly, 207 Ill.2d 555, 567-68, 280 Ill.Dec. 311, 802 N.E.2d 236, 244-45 (2003). A court may, however, assume that a section 2-1401 petitioner is entitled to the same level of assistance as a postconviction petitioner. Pinkonsly, 207 Ill.2d at 568, 280 Ill.Dec. 311, 802 N.E.2d at 245.
We find that Welch was provided reasonable assistance of counsel regarding his section 2-1401 petition. The record establishes that Welch's appointed counsel acknowledged that Welch had submitted a petition under section 2-1401 of the Civil Code but recognized that Welch's constitutional claims were not cognizable in a section 2-1401 petition. Whether he based his determination on timeliness grounds or substantive reasons, we agree that seeking to recharacterize the petition was the proper avenue for counsel to pursue. A section 2-1401 petition is designed to correct factual errors that were unknown and not before the trial court. Welch's claim that his sentence was void concerns a matter of law and could only be brought in postconviction proceedings. Counsel performed reasonably in recasting Welch's section 2-1401 petition as a postconviction petition. Pinkonsly, 207 Ill.2d at 568, 280 Ill.Dec. 311, 802 N.E.2d at 245 ("defendant's attorney was not unreasonable for failing to raise a putative legal error in a proceeding where only fact errors are cognizable"). While Welch argues on appeal that counsel did not fulfill his obligations as evidenced by the trial court's failure to rule on either his 2-1401 petition or the State's motion to dismiss the petition, because the section 2-1401 petition was recast as a postconviction petition, there was no section 2-1401 petition on which the trial court could rule.
We further conclude that counsel was not deficient in failing to advocate Welch's claim that his sentences were void. Welch asserted in his section 2-1401 petition that his sentences were void because the offenses for which he was convicted were part of a single course of conduct with no substantial change in criminal objective for which consecutive sentences could not be imposed per section 5-8-4(a) of the Corrections Code. 730 ILCS 5/5-8-4(a) (West 1994). His attorney did not advocate Welch's position in an amended section 2-1401 petition or raise it in the recast postconviction petition. Because Welch's consecutive sentences were not void, counsel was not deficient in failing to advocate Welch's void sentences claim.
"Whether a judgment is void or voidable presents a question of jurisdiction." People v. Davis, 156 Ill.2d 149, 155, 189 Ill.Dec. 49, 619 N.E.2d 750, 754 (1993). A judgment is void when the court that *761 entered it lacked jurisdiction while a voidable judgment is one entered in error by a trial court acting within its jurisdiction. People v. Raczkowski, 359 Ill.App.3d 494, 496-97, 296 Ill.Dec. 39, 834 N.E.2d 596, 599 (2005). A void judgment may be attacked at any time, directly or collaterally; in contrast, a voidable judgment is correctable on review only if timely appealed. Raczkowski, 359 Ill.App.3d at 497, 296 Ill. Dec. 39, 834 N.E.2d at 599. A court does not lose jurisdiction because it makes a mistake in the facts, law or both. Davis, 156 Ill.2d at 156, 189 Ill.Dec. 49, 619 N.E.2d at 754. A judgment may be void, however, where the trial court exceeded its jurisdiction. Davis, 156 Ill.2d at 156, 189 Ill.Dec. 49, 619 N.E.2d at 754-55.
Welch does not argue that the trial court lacked jurisdiction at the time he was sentenced. Rather, he contends that the trial court erroneously determined that his offenses were not part of a single course of conduct and thus consecutive sentences were not authorized under section 5-8-4(a). The trial court had statutory authority under section 5-8-4 to impose consecutive sentences if it made the requisite findings. Under section 5-8-4(a), "the court shall not impose consecutive sentences for offenses which were committed as part of a single course of conduct during which there was no substantial change in the nature of the criminal objective." 730 ILCS 5/5-8-4(a) (West 1994). Under section 5-8-4(b), the court shall not impose consecutive sentences "unless, having regard to the nature and circumstances of the offense and the history and character of the defendant, it is of the opinion that such a term is required to protect the public from further criminal conduct by the defendant" as set forth in the record. 730 ILCS 5/5-8-4(b) (West 1994).
The record establishes that at the sentencing hearing, the trial court made findings as required under section 5-8-4(a) and (b), specifically stating that the armed robbery and armed violence were not committed as part as a single course of conduct, that there was a substantial change in the nature of Welch's criminal objective, and that Welch was "a very dangerous" person from whose criminal conduct the public needed protection. While Welch may argue that the trial court's findings regarding the "single course of conduct" requirement were in error, the trial court had jurisdiction to impose consecutive sentences based on its findings as required under sections 5-8-4(a) and (b). People v. Wilder, 325 Ill.App.3d 987, 1003, 260 Ill. Dec. 79, 760 N.E.2d 496, 510 (2001) (consecutive sentences are appropriate where the offenses were not part of a single course of conduct and the court specifically finds on the record that consecutive sentences are necessary to protect the public). Because the court had jurisdiction, any error the court made in imposing consecutive sentences renders the judgment voidable, not void. To challenge a voidable judgment, Welch was required to timely do so. Accordingly, we conclude that Welch's counsel did not perform deficiently in either failing to advocate Welch's void sentence claim or include the claim in the amended successive postconviction petition.
Having determined that Welch was provided reasonable assistance, we turn now to whether the trial court erred by considering the State's objection and the arguments of the parties when it denied Welch's motion for leave to file a successive postconviction petition. Welch argues that input by the State was improper and urges this court to reverse the dismissal of his petition and remand for further postconviction proceedings.
As an initial matter, we acknowledge that this court inaptly framed this issue *762 when it denied the appellate defender's Finley motion and requested additional briefing from the parties. As discussed below, the record clarifies that Welch's successive postconviction petition never made it to the first stage of proceedings. Rather, the trial court denied his motion for leave to file the petition. Thus, properly framed, the issue is whether the trial court improperly allowed input by the State when it considered Welch's motion for leave to file his successive petition. Our review is de novo. People v. Collier, 387 Ill.App.3d 630, 633-34, 326 Ill.Dec. 760, 900 N.E.2d 396, 401 (2008).
Section 122-1(f) of the Act requires that a petitioner obtain leave of court before filing a successive postconviction petition and provides that leave may be granted only up on a demonstration of both cause for a petitioner's failure to bring the claim in his initial postconviction petition and resulting prejudice. 725 ILCS 5/122-1(f) (West 2006); People v. LaPointe, 227 Ill.2d 39, 44, 316 Ill.Dec. 208, 879 N.E.2d 275, 278 (2007). A successive postconviction petition is not considered filed until the petitioner has obtained leave of court. People v. Spivey, 377 Ill. App.3d 146, 149, 316 Ill.Dec. 324, 879 N.E.2d 391, 395 (2007). Where a defendant fails to first satisfy the requirements under section 122-1(f), a reviewing court does not reach the merits or consider whether his successive postconviction petition states the gist of a constitutional claim. People v. Wyles, 383 Ill.App.3d 271, 274, 322 Ill.Dec. 422, 891 N.E.2d 437, 439-40 (2008).
In the instant case, the record indicates that both parties participated in arguments regarding Welch's motion for leave to file his successive petition. Welch's counsel expressly stated that he was not seeking a hearing on the merits of the petition but was requesting leave based on fundamental fairness principles. The State responded that the severance issue raised in the successive petition had been determined in prior proceedings. The parties have not offered, and we have not found, any authority prohibiting input from the State at this stage of postconviction proceedings. The trial court found that Welch failed to satisfy the cause and prejudice requirements, noting that he had raised the severance issue at every stage of the proceedings. In denying leave, the trial court found that the issue had been fully litigated; that if not, it was waived; and if not waived, it was barred for failure to establish cause and prejudice. We find no error in its determination.
For the foregoing reasons, the judgment of the circuit court of Rock Island County is affirmed.
Affirmed.
HOLDRIDGE and McDADE, JJ., concur.
