From 1340486ca21d61438b579ba3c0b676ff0e68e8fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Gilles?= <sebastien.gilles@inria.fr> Date: Mon, 10 May 2021 17:54:25 +0200 Subject: [PATCH] Reformulation (mix of version before Vincent's change and his version). --- 3-Operators/4-CanonicalForm.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/3-Operators/4-CanonicalForm.ipynb b/3-Operators/4-CanonicalForm.ipynb index 0958b10..ef5ca7a 100644 --- a/3-Operators/4-CanonicalForm.ipynb +++ b/3-Operators/4-CanonicalForm.ipynb @@ -195,7 +195,7 @@ "** Error in `./prog.exe': double free or corruption (fasttop): 0x0000000001532da0 **\n", "```\n", "\n", - "So what's the deal? The default operator copies all the data attributes from `v1` to `v2`... which here amounts only to the `array_` pointer. But it really copies that, the pointer, and not the data pointed by this pointer. So in fine v1 and v2 points to the same area of memory, and the issue is that we attempt to free the same memory twice.\n", + "So what's the deal? The default operator copies all the data attributes from `v1` to `v2`... which here amounts only to the `array_` pointer. But it really copies that: the pointer itself, _not_ the data pointed by this pointer. So in fine v1 and v2 points to the same area of memory, and the issue is that we attempt to free the same memory twice.\n", "\n", "One way to solve this is not to use a dynamic array - for instance you would be cool with a `std::vector`. But we can do so properly by hand as well (in practice don't - stick with `std::vector`!):\n" ] -- GitLab