# \[PATCH\] respect HAVE\_MALLOC\_H

- Subsystems: THE REST
- Maintainers: Linus Torvalds
- List: linux-ext4
- 2 messages, 2 authors
- Page: https://ratatoskr.run/linux-ext4/2012/08/13415921/t

## \[PATCH\] respect HAVE\_MALLOC\_H

- From: Mike Frysinger \<hidden\>
- Date: 2012-08-18 22:17:40 
- Message: https://ratatoskr.run/linux-ext4/2012/08/13415921.md

```text
Most places respect this define, but this one doesn't.

Reported-by: Dmitri Bogomolov <redacted>
Signed-off-by: Mike Frysinger <redacted>
---
 util/symlinks.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/util/symlinks.c b/util/symlinks.c
index f3a632a..abb33f8 100644
--- a/util/symlinks.c
+++ b/util/symlinks.c
@@ -8,7 +8,9 @@
 #endif
 #include <stdio.h>
 #include <stdlib.h>
+#ifdef HAVE_MALLOC_H
 #include <malloc.h>
+#endif
 #include <string.h>
 #include <fcntl.h>
 #include <sys/param.h>
-- 
1.7.9.7

```

## Re: respect HAVE\_MALLOC\_H

- From: Theodore Ts'o \<tytso@mit.edu\>
- Date: 2012-08-19 21:57:46 
- Message: https://ratatoskr.run/linux-ext4/2012/08/13415924.md

```text
On Sat, Aug 18, 2012 at 12:17:41PM -0000, Mike Frysinger wrote:
> Most places respect this define, but this one doesn't.
> 
> Reported-by: Dmitri Bogomolov <redacted>
> Signed-off-by: Mike Frysinger <redacted>

Applied to the maint branch, thanks.

					- Ted
```
