Skip to content
Extraits de code Groupes Projets
Valider d50c3575 rédigé par Rodrigo Braz Monteiro's avatar Rodrigo Braz Monteiro
Parcourir les fichiers

Fixed crash on charset detection.

Originally committed to SVN as r1811.
parent ed29ba8f
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -69,6 +69,7 @@ wxString CharSetDetect::GetEncoding(wxString filename) { ...@@ -69,6 +69,7 @@ wxString CharSetDetect::GetEncoding(wxString filename) {
// Grab every result obtained // Grab every result obtained
std::list<CharDetResult> results; std::list<CharDetResult> results;
for (int i=0;i<NUM_OF_CHARSET_PROBERS;i++) { for (int i=0;i<NUM_OF_CHARSET_PROBERS;i++) {
if (mCharSetProbers[i]) {
int probes = mCharSetProbers[i]->GetProbeCount(); int probes = mCharSetProbers[i]->GetProbeCount();
for (int j=0;j<probes;j++) { for (int j=0;j<probes;j++) {
float conf = mCharSetProbers[i]->GetConfidence(j); float conf = mCharSetProbers[i]->GetConfidence(j);
...@@ -81,6 +82,7 @@ wxString CharSetDetect::GetEncoding(wxString filename) { ...@@ -81,6 +82,7 @@ wxString CharSetDetect::GetEncoding(wxString filename) {
} }
} }
} }
}
// If you got more than one valid result, ask the user which he wants // If you got more than one valid result, ask the user which he wants
if (results.size() > 1) { if (results.size() > 1) {
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter