Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

122
Visualizações
Ctype Windows access violation reading 0x733B7359

I use Ctype in my Django project but when I use this method :

def requete_smartphone(self, bande, debut_a, debut_m, debut_j, fin_a, fin_m, fin_j, sens, fvitesse, fstat, affmes,
                       min, max, moyenne, ecart, algofusion, s_route, vitesse, s_capteurs, s_typeveh, s_marque,
                       s_modele, s_immatriculation, s_pseudo, ecart_moyenne, nombre):
    """ Permet de faire la requete smarphone avec tout les paramètre qu'elle demande

    Paramètres :
    Les même que pour la DLL, suivre ce qui est écrit sur la fiche de la DLL

    Renvoie
    """
    bande = str.encode(bande)
    debut_a = int(debut_a)
    debut_m = int(debut_m)
    debut_j = int(debut_j)
    fin_a = int(fin_a)
    fin_m = int(fin_m)
    fin_j = int(fin_j)
    sens = str.encode(sens)
    fvitesse = str.encode(fvitesse)
    fstat = str.encode(fstat)
    affmes = str.encode(affmes)
    min = str.encode(min)
    max = str.encode(max)
    moyenne = str.encode(moyenne)
    ecart = str.encode(ecart)
    algofusion = str.encode(algofusion)
    s_route = str.encode(s_route)
    vitesse = float(vitesse)
    s_capteurs = str.encode(s_capteurs)
    s_typeveh = str.encode(s_typeveh)
    s_marque = str.encode(s_marque)
    s_modele = str.encode(s_modele)
    s_immatriculation = str.encode(s_immatriculation)
    s_pseudo = str.encode(s_pseudo)
    ecart_moyenne = float(ecart_moyenne)
    nombre = str.encode(nombre)
    print("c1")
    DLLFunction = self.libraryBase.requete_smartphone
    print("c2")
    DLLFunction.argtypes = [c_char, c_int, c_int, c_int, c_int, c_int, c_int, c_char, c_char, c_char, c_char,
                            c_char, c_char, c_char, c_char, c_char, c_char_p, c_float, c_char_p, c_char_p, c_char_p,
                            c_char_p, c_char_p, c_char_p, c_float, c_char]
    print("c3")
    DLLFunction.restype = c_bool
    print("c4")
    resultFunction = DLLFunction(bande, debut_a, debut_m, debut_j, fin_a, fin_m, fin_j, sens, fvitesse, fstat, affmes, min, max, moyenne, ecart, algofusion, s_route, vitesse, s_capteurs, s_typeveh, s_marque, s_modele, s_immatriculation, s_pseudo, ecart_moyenne, nombre)

    return resultFunction

Sometimes I have this error : OSError: exception: access violation reading 0x733B7359 Sometimes it's 0x733B7359. It's possibly a problem with my argument, I don't know if .encode('utf-8') it's really the best method.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

I find the problem : It's wasn't my DLL and when I search in the method requete_smartphone in C. In this method all my c_char was use like a integer and use in array (for exemple array[bande] and my encode of c_char was in UTF-8, so when array[bande] try to point to array in index 1, with the encode he point to array in index 49. So I change DLL to have integer.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda