aboutsummaryrefslogtreecommitdiffstats
path: root/erts/lib_src/common/erl_misc_utils.c
diff options
context:
space:
mode:
authorCristian Greco <[email protected]>2011-02-23 01:41:23 +0100
committerCristian Greco <[email protected]>2011-02-23 01:41:23 +0100
commit47f9ef2ee5f3d9a79038fe8318c740a7c4345541 (patch)
treeea5828c08ce1c175aa8aa61667903eba042cee56 /erts/lib_src/common/erl_misc_utils.c
parentb0d6abb72cf32df548703b284b737a4a7c0a9d8a (diff)
downloadotp-47f9ef2ee5f3d9a79038fe8318c740a7c4345541.tar.gz
otp-47f9ef2ee5f3d9a79038fe8318c740a7c4345541.tar.bz2
otp-47f9ef2ee5f3d9a79038fe8318c740a7c4345541.zip
Fix some wrong pointer dereferences
Diffstat (limited to 'erts/lib_src/common/erl_misc_utils.c')
-rw-r--r--erts/lib_src/common/erl_misc_utils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/erts/lib_src/common/erl_misc_utils.c b/erts/lib_src/common/erl_misc_utils.c
index 4c881993a5..ec729407bb 100644
--- a/erts/lib_src/common/erl_misc_utils.c
+++ b/erts/lib_src/common/erl_misc_utils.c
@@ -813,7 +813,7 @@ read_topology(erts_cpu_info_t *cpuinfo)
cpuinfo->topology = malloc(sizeof(erts_cpu_topology_t)
* cpuinfo->configured);
- if (!cpuinfo)
+ if (!cpuinfo->topology)
goto error;
for (ix = 0; ix < cpuinfo->configured; ix++) {
@@ -1023,7 +1023,7 @@ read_topology(erts_cpu_info_t *cpuinfo)
cpuinfo->topology = malloc(sizeof(erts_cpu_topology_t)
* cpuinfo->configured);
- if (!cpuinfo)
+ if (!cpuinfo->topology)
goto error;
for (ix = 0; ix < cpuinfo->configured; ix++) {