Exception in thread "main" java.io.IOException: Server returned HTTP response code: 401 for URL: https://android.apis.google.com/c2dm/send
라는 에러가 나는데 인증관련된거 같기도 하고...
느낌에는 auth token값이 잘못되서 구글 서버 인증을 못받는건지,ㅠㅠ.. regId값이 잘못되서 인증이 안되는건지... 그럴꺼 같은데요....
HttpsURLConnection conn = (HttpsURLConnection)url.openConnection();
conn.setHostnameVerifier(DO_NOT_VERIFY);
conn.setDoOutput(true);
conn.setUseCaches(false);
conn.setRequestMethod("POST");
conn.setRequestProperty("Content-Type", "application/x-www-form-urlencoded");
conn.setRequestProperty("Content-Length", Integer.toString(postData.length));
conn.setRequestProperty("Authorization", "GoogleLogin auth=" + authToken);
OutputStream out = conn.getOutputStream();
out.write(postData);
out.close();
conn.getInputStream(); <--요기서 딱 걸리네여....ㅠ_ㅜ 아오 답답해 죽겠습니다......id나 토큰값이 틀려서 걸리는거 같은데...OTL
혹시 저 에러 나보신분 계시는지 모르겠네요...ㅠㅠ
고수님들 제발 도움을....




INTERNET Permission은 추가 해놓으셨는지요?