| Summary: | the size of allocated memory may be wrong | ||
|---|---|---|---|
| Product: | [Community] GlusterFS | Reporter: | rick <donyren> |
| Component: | replicate | Assignee: | Pranith Kumar K <pkarampu> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | |
| Severity: | medium | Docs Contact: | |
| Priority: | high | ||
| Version: | 3.1.2 | CC: | gluster-bugs, rabhat, rahulcs |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | Type: | --- | |
| Regression: | RTNR | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
|
Description
rick
2011-03-11 07:38:55 UTC
PATCH: http://patches.gluster.com/patch/6415 in master (cluster/afr: Fix wrong memory allocation) Thanks a lot for pointing it out Rick. size_t pending_xattr_size = 3 * sizeof (int32_t);
/* 3 = data+metadata+entry */
index = afr_index_for_transaction_type (type);
for (i = 0; i < priv->child_count; i++) {
arr = GF_CALLOC (1, pending_xattr_size,
gf_afr_mt_char);
if (!arr) {
ret = -1;
goto out;
}
This is fixed now as per the code.
|