repositories
/
TD_C.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
00d8856
)
TP_8 exo2: be more explicative about a false malloc invocation.
author
Jérôme Benoit
<jerome.benoit@piment-noir.org>
Tue, 28 Feb 2017 14:32:36 +0000
(15:32 +0100)
committer
Jérôme Benoit
<jerome.benoit@piment-noir.org>
Tue, 28 Feb 2017 14:32:36 +0000
(15:32 +0100)
Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
TP_8/exo1/exo1.c
patch
|
blob
|
blame
|
history
diff --git
a/TP_8/exo1/exo1.c
b/TP_8/exo1/exo1.c
index beea2f689f02cc43e785b4eb3077f2bcd6de5f79..b0e5df93e53151a5cd8ad194b842f159162cc486 100644
(file)
--- a/
TP_8/exo1/exo1.c
+++ b/
TP_8/exo1/exo1.c
@@
-11,7
+11,7
@@
int main() {
int* arr;
printf("Longeur?\n");
int size = promptValue();
- //arr = malloc(sizeof(arr[size]));
+ //arr = malloc(sizeof(arr[size]));
prend la taille de l'élément à la position de l'index = size
arr = malloc(sizeof(int)*size);
for (int i = 0; i < size; i++) {