This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 247811 - StackOverflowError at java.util.regex.Pattern$Ques.match
Summary: StackOverflowError at java.util.regex.Pattern$Ques.match
Status: RESOLVED WORKSFORME
Alias: None
Product: platform
Classification: Unclassified
Component: JDK Problems (show other bugs)
Version: 7.4
Hardware: All All
: P3 normal (vote)
Assignee: Antonin Nebuzelsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-09 05:57 UTC by pengamat_hebat
Modified: 2015-09-14 14:31 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 206049


Attachments
stacktrace (64.22 KB, text/plain)
2014-10-09 05:57 UTC, pengamat_hebat
Details

Note You need to log in before you can comment on or make changes to this bug.
Description pengamat_hebat 2014-10-09 05:57:32 UTC
Build: NetBeans IDE 7.4 Beta (Build 201307092200)
VM: Java HotSpot(TM) 64-Bit Server VM, 24.51-b03, Java(TM) SE Runtime Environment, 1.7.0_51-b13
OS: Windows 8

User Comments:
tipirneni: Started sample program and ran it. got this exception

GUEST: during work

GUEST: Send my program.
package ???????.??.?????;
import java.io.*;
public class ?????????????? {

    public static String otvet="";
    public static int k=0;
    
    public static void main(String[] args) throws IOException{
    BufferedReader br=new BufferedReader(new InputStreamReader(System.in,"windows-1251"));
    System.out.println("??????? ???????");
    String a=br.readLine();
    System.out.println("??????? ????????");
    String b=br.readLine();
    System.out.println("??????? ?????????? ?????? ????? ???????. ????? ??? ??????????");
    int znak=Integer.parseInt(br.readLine());
//    String a="239123";
//    String b="218933127393";
//    int znak=2;
    if (a.equals("0"))
        System.out.println("0");
    else
        if (b.equals("0"))
            System.out.println("?? ???? ?????? ??????");
    else
        {
        int l_f=a.length();                            // ???????? ?????, ???? ????? ??????? 
        int l_s=b.length();                            // + ?????????? ??

GUEST: I was testing the algorithm for regular expression matching

pengamat_hebat: I try System.out.println(cipher);
cipher is a string contain 5957 character (1 and 0)

GUEST: Crash when loop system.out.print("x") for 20000 times.

GUEST: System.out.println(bd) where bd is a large BigDecimal - 10000 digits




Stacktrace: 
java.lang.StackOverflowError
   at java.util.regex.Pattern$Ques.match(Pattern.java:4077)
   at java.util.regex.Pattern$GroupHead.match(Pattern.java:4556)
   at java.util.regex.Pattern$Loop.match(Pattern.java:4683)
   at java.util.regex.Pattern$GroupTail.match(Pattern.java:4615)
   at java.util.regex.Pattern$BmpCharProperty.match(Pattern.java:3715)
   at java.util.regex.Pattern$Ques.match(Pattern.java:4079)
Comment 1 pengamat_hebat 2014-10-09 05:57:35 UTC
Created attachment 149795 [details]
stacktrace
Comment 2 Antonin Nebuzelsky 2015-09-14 14:31:33 UTC
All exception reports from 7.4. Presumably fixed since then.