diff --git a/loyalty/src/main/webapp/jsp/config.jsp b/loyalty/src/main/webapp/jsp/config.jsp index 626d35d..4d00e43 100644 --- a/loyalty/src/main/webapp/jsp/config.jsp +++ b/loyalty/src/main/webapp/jsp/config.jsp @@ -70,6 +70,7 @@ // // close the DB first st.close(); + conn.close(); } catch (Exception e) { // not a very good practice to print out error in webpage.... diff --git a/loyalty/src/main/webapp/jsp/confirm.jsp b/loyalty/src/main/webapp/jsp/confirm.jsp index 48f10c5..5d717bb 100644 --- a/loyalty/src/main/webapp/jsp/confirm.jsp +++ b/loyalty/src/main/webapp/jsp/confirm.jsp @@ -101,6 +101,7 @@ // close the DB first st.close(); + conn.close(); // This is the most tricky party // // To send notification to MCS diff --git a/loyalty/src/main/webapp/jsp/custsearch.jsp b/loyalty/src/main/webapp/jsp/custsearch.jsp index 4e3d3ad..191fadc 100644 --- a/loyalty/src/main/webapp/jsp/custsearch.jsp +++ b/loyalty/src/main/webapp/jsp/custsearch.jsp @@ -42,6 +42,7 @@ } // again, we should close DB connection st.close(); + conn.close(); } catch (Exception e) { // same as welcome.jsp - to-do to put error message to backend out.println("Exception : " + e.getMessage() + ""); @@ -86,6 +87,7 @@ out.println(">" + prod + ""); } st.close(); + conn.close(); } catch (Exception e) { out.println("Exception : " + e.getMessage() + ""); diff --git a/loyalty/src/main/webapp/jsp/mbeconfirm.jsp b/loyalty/src/main/webapp/jsp/mbeconfirm.jsp index 965ca8a..7c2bd14 100644 --- a/loyalty/src/main/webapp/jsp/mbeconfirm.jsp +++ b/loyalty/src/main/webapp/jsp/mbeconfirm.jsp @@ -59,6 +59,7 @@ // close the DB first st.close(); + conn.close(); // This is the most tricky party // // To send notification to MCS diff --git a/loyalty/src/main/webapp/jsp/welcome.jsp b/loyalty/src/main/webapp/jsp/welcome.jsp index 8488e3b..dc463e4 100644 --- a/loyalty/src/main/webapp/jsp/welcome.jsp +++ b/loyalty/src/main/webapp/jsp/welcome.jsp @@ -113,6 +113,7 @@ } // always remember close DB connection st.close(); + conn.close(); } catch (Exception e) { // not a very good practice to print out error in webpage....