[please Help] erreur de segmentation !!!!!
breton_a
-
ahmet -
ahmet -
Coucou tt le monde !!
g une erreur de segmentation juste avant le check point 6. Je vois pas du tout a quoi c du !!
Si qqun pouvait m'aider, ca serait ultra giga over mega COOOOOL :D
Voila le fichier increminé :)
[cpp]
#include <stdlib.h>
#include <stdio.h>
#include "tfd.h"
#include <math.h>
int tfd2d(double **x,double **xtre,double **xtim,int Width, int Height)
{
long i,j;
double *x_re=NULL, *x_im=NULL;
int max;
x_re=malloc(max*sizeof(double));
x_im=malloc(max*sizeof(double));
/* if (x_re==NULL || x_im==NULL){
printf("pfffffffffffffffffffffffffffffffffffffffffffffffff\n");
return EXIT_FAILURE;
}*/
printf("check point 1\n");
if (Width>=Height) {
printf("check point 2\n");
max=Width;
printf("check point 3 max = %d\n", max);
}
else {
printf("check point 4\n");
max = Height;
printf("check point 5 max = %d\n", max);
}
printf("check point 6");
max = Height;
printf("max=%d",max);
printf("check point 7");
//transformée des lignes
for(i=0;i<Height;i++){
for(j=0;j<Width;j++){
x_re[j]=x[i][j];
x_im[j]=0;
tfd(x_re,x_im,Width,Height);
}
}
//transformée des colonnes
for(j=0;j<Width;j++){
for(i=0;i<Height;i++){
tfd(x_re,x_im,Height,Width);
}
}
return EXIT_SUCCESS;
}
[/cpp]
g une erreur de segmentation juste avant le check point 6. Je vois pas du tout a quoi c du !!
Si qqun pouvait m'aider, ca serait ultra giga over mega COOOOOL :D
Voila le fichier increminé :)
[cpp]
#include <stdlib.h>
#include <stdio.h>
#include "tfd.h"
#include <math.h>
int tfd2d(double **x,double **xtre,double **xtim,int Width, int Height)
{
long i,j;
double *x_re=NULL, *x_im=NULL;
int max;
x_re=malloc(max*sizeof(double));
x_im=malloc(max*sizeof(double));
/* if (x_re==NULL || x_im==NULL){
printf("pfffffffffffffffffffffffffffffffffffffffffffffffff\n");
return EXIT_FAILURE;
}*/
printf("check point 1\n");
if (Width>=Height) {
printf("check point 2\n");
max=Width;
printf("check point 3 max = %d\n", max);
}
else {
printf("check point 4\n");
max = Height;
printf("check point 5 max = %d\n", max);
}
printf("check point 6");
max = Height;
printf("max=%d",max);
printf("check point 7");
//transformée des lignes
for(i=0;i<Height;i++){
for(j=0;j<Width;j++){
x_re[j]=x[i][j];
x_im[j]=0;
tfd(x_re,x_im,Width,Height);
}
}
//transformée des colonnes
for(j=0;j<Width;j++){
for(i=0;i<Height;i++){
tfd(x_re,x_im,Height,Width);
}
}
return EXIT_SUCCESS;
}
[/cpp]
A voir également:
- [please Help] erreur de segmentation !!!!!
- Erreur t32 ✓ - Forum Livebox
- Erreur upes 1025 - Forum Téléviseurs
- Erreur 3000 france tv - Forum Lecteurs et supports vidéo
- Erreur 0x80070643 - Accueil - Windows
- Corriger l'erreur 0x80070643 de la mise à jour KB5034441 de Windows 10 - Accueil - Windows