Changeset 451:f4a1e8ad3847
- Timestamp:
- 01/08/2013 02:20:08 PM (5 months ago)
- Author:
- Andreas Schaefer <gentryx@…>
- Branch:
- default
- Message:
-
coding style
- Files:
-
Legend:
- Unmodified
- Added
- Removed
-
|
r450
|
r451
|
|
| 42 | 42 | // array's start. Ugly, but it works. |
| 43 | 43 | char *chunk = std::allocator<char>().allocate(upsize(n)); |
| 44 | | if (chunk == 0) |
| | 44 | if (chunk == 0) { |
| 45 | 45 | return (pointer)chunk; |
| | 46 | } |
| | 47 | |
| 46 | 48 | size_type offset = (size_type)chunk % ALIGNMENT; |
| 47 | 49 | size_type correction = ALIGNMENT - offset; |
| … |
… |
|
| 55 | 57 | void deallocate(pointer p, size_type n) |
| 56 | 58 | { |
| 57 | | if (p == 0) |
| | 59 | if (p == 0) { |
| 58 | 60 | return; |
| | 61 | } |
| | 62 | |
| 59 | 63 | char *actual; |
| 60 | 64 | // retrieve the original pointer which sits in front of its |