Debian Codegraph @

po/nl/man3/malloc.3.po

raw
1 # Dutch translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # Jos Boersema <[email protected]>, 2001.
5 # Mario Blättermann <[email protected]>, 2019.
6 # Luc Castermans <[email protected]>, 2021-2023, 2024, 2025, 2026.
7 msgid ""
8 msgstr ""
9 "Project-Id-Version: manpages-l10n 2.15\n"
10 "POT-Creation-Date: 2026-06-05 06:30+0200\n"
11 "PO-Revision-Date: 2026-03-27 09:09+0100\n"
12 "Last-Translator: Luc Castermans <[email protected]>\n"
13 "Language-Team: Dutch <[email protected]>\n"
14 "Language: nl_NL\n"
15 "MIME-Version: 1.0\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
18 "Plural-Forms: nplurals=2; plural=(n != 1)\n"
19 "X-Generator: Lokalize 25.12.1\n"
20
21 #. type: TH
22 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
23 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
24 #, no-wrap
25 msgid "malloc"
26 msgstr "malloc"
27
28 #. type: TH
29 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
30 #: opensuse-tumbleweed
31 #, no-wrap
32 msgid "2026-02-08"
33 msgstr "8 februari 2026"
34
35 #. type: TH
36 #: archlinux debian-unstable
37 #, fuzzy, no-wrap
38 #| msgid "Linux man-pages 6.17"
39 msgid "Linux man-pages 6.18"
40 msgstr "Linux man-paginas 6.17"
41
42 #. type: SH
43 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
44 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
45 #, no-wrap
46 msgid "NAME"
47 msgstr "NAAM"
48
49 #. type: Plain text
50 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
51 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
52 msgid ""
53 "malloc, free, calloc, realloc, reallocarray - allocate and free dynamic "
54 "memory"
55 msgstr ""
56 "malloc, free, calloc, realloc - reserveren en vrijmaken van dynamisch "
57 "geheugen"
58
59 #. type: SH
60 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
61 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
62 #, no-wrap
63 msgid "LIBRARY"
64 msgstr "BIBLIOTHEEK"
65
66 #. type: Plain text
67 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
68 #: opensuse-leap-16-1 opensuse-tumbleweed
69 msgid "Standard C library (I<libc>,\\ I<-lc>)"
70 msgstr "Standaard C bibliotheek (I<libc>, I<-lc>)"
71
72 #. type: SH
73 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
74 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
75 #, no-wrap
76 msgid "SYNOPSIS"
77 msgstr "SAMENVATTING"
78
79 #. type: Plain text
80 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
81 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
82 #, no-wrap
83 msgid "B<#include E<lt>stdlib.hE<gt>>\n"
84 msgstr "B<#include E<lt>stdlib.hE<gt>>\n"
85
86 #. type: Plain text
87 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
88 #: opensuse-tumbleweed
89 #, no-wrap
90 msgid ""
91 "B<void *malloc(size_t >I<size>B<);>\n"
92 "B<void free(void *_Nullable >I<p>B<);>\n"
93 "B<void *calloc(size_t >I<n>B<, size_t >I<size>B<);>\n"
94 "B<void *realloc(void *_Nullable >I<p>B<, size_t >I<size>B<);>\n"
95 "B<void *reallocarray(void *_Nullable >I<p>B<, size_t >I<n>B<, size_t >I<size>B<);>\n"
96 msgstr ""
97 "B<void *malloc(size_t >I<size>B<);>\n"
98 "B<void free(void *_Nullable >I<p>B<);>\n"
99 "B<void *calloc(size_t >I<n>B<, size_t >I<size>B<);>\n"
100 "B<void *realloc(void *_Nullable >I<p>B<, size_t >I<size>B<);>\n"
101 "B<void *reallocarray(void *_Nullable >I<p>B<, size_t >I<n>B<, size_t >I<size>B<);>\n"
102
103 #. type: Plain text
104 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
105 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
106 msgid ""
107 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
108 msgstr ""
109 "Feature Test Macro Requirements voor glibc (zie B<feature_test_macros>(7)):"
110
111 #. type: Plain text
112 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
113 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
114 msgid "B<reallocarray>():"
115 msgstr "B<reallocarray>():"
116
117 #. type: Plain text
118 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
119 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
120 #, no-wrap
121 msgid ""
122 " Since glibc 2.29:\n"
123 " _DEFAULT_SOURCE\n"
124 " glibc 2.28 and earlier:\n"
125 " _GNU_SOURCE\n"
126 msgstr ""
127 " Sinds glibc 2.29:\n"
128 " _DEFAULT_SOURCE\n"
129 " Glibc 2.28 en eerder:\n"
130 " _GNU_SOURCE\n"
131
132 #. type: SH
133 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
134 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
135 #, no-wrap
136 msgid "DESCRIPTION"
137 msgstr "BESCHRIJVING"
138
139 #. type: SS
140 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
141 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
142 #, no-wrap
143 msgid "malloc()"
144 msgstr "malloc()"
145
146 #. type: Plain text
147 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
148 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
149 msgid ""
150 "The B<malloc>() function allocates I<size> bytes and returns a pointer to "
151 "the allocated memory. I<The memory is not initialized>. If I<size> is 0, "
152 "then B<malloc>() returns a unique pointer value that can later be "
153 "successfully passed to B<free>(). (See \"Nonportable behavior\" for "
154 "portability issues.)"
155 msgstr ""
156 "De B<malloc>() functie reserveert I<grootte> bytes geheugen en geeft een "
157 "wijzer naar het gereserveerde geheugen terug. I<Het geheugen wordt niet "
158 "geinitialiseerd>. Als I<grootte> gelijk is aan 0, dan retourneert "
159 "B<malloc>() een unieke wijzer waarde die later kan worden mee gegeven aan "
160 "B<free>(). (Zie \"Niet overdraagbaar gebrag\" voor overdraagbaarheids "
161 "onderwerpen)"
162
163 #. type: SS
164 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
165 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
166 #, no-wrap
167 msgid "free()"
168 msgstr "free()"
169
170 #. type: Plain text
171 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
172 #: opensuse-tumbleweed
173 msgid ""
174 "The B<free>() function frees the memory space pointed to by I<p>, which "
175 "must have been returned by a previous call to B<malloc>() or related "
176 "functions. Otherwise, or if I<p> has already been freed, undefined behavior "
177 "occurs. If I<p> is NULL, no operation is performed."
178 msgstr ""
179 "De B<free>() functie geeft de geheugen-ruimte waar I<wzr> naar wijst vrij, "
180 "die moet zijn teruggegeven door een eerdere aanroep naar B<malloc>() of "
181 "gerelateerde functies.Anders, of als I<wzr> al eerder werd vrijgegeven, "
182 "ontstaat ongedefinieerd gedrag. Als I<wzr> gelijk is aan NULL wordt niks "
183 "uitgevoerd."
184
185 #. type: SS
186 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
187 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
188 #, no-wrap
189 msgid "calloc()"
190 msgstr "calloc()"
191
192 #. type: Plain text
193 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
194 #: opensuse-leap-16-1 opensuse-tumbleweed
195 msgid ""
196 "The B<calloc>() function allocates memory for an array of I<n> elements of "
197 "I<size> bytes each and returns a pointer to the allocated memory. The "
198 "memory is set to zero. If I<n> or I<size> is 0, then B<calloc>() returns a "
199 "unique pointer value that can later be successfully passed to B<free>()."
200 msgstr ""
201 "De B<calloc>() functie reserveert I<grootte> bytes geheugen voor een array "
202 "en geeft een wijzer naar het gereserveerde geheugen terug. Het geheugen "
203 "wordt met nul geïnitialiseerd. Als I<n> of I<grootte> gelijk is aan 0, dan "
204 "retourneert B<calloc>() een unieke wijzer waarde die later succesvol kan "
205 "worden mee gegeven aan B<free>()."
206
207 #. type: Plain text
208 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
209 #: opensuse-leap-16-1 opensuse-tumbleweed
210 msgid ""
211 "If the multiplication of I<n> and I<size> would result in integer overflow, "
212 "then B<calloc>() returns an error. By contrast, an integer overflow would "
213 "not be detected in the following call to B<malloc>(), with the result that "
214 "an incorrectly sized block of memory would be allocated:"
215 msgstr ""
216 "Als de vermenigvuldiging van I<n> en I<grootte> zou resulteren in het "
217 "overlopen van een geheel getal, dan geeft B<calloc>() een fout terug. In "
218 "tegenstelling daarmee, zou het overlopen van een geheel getal niet "
219 "gedetecteerd worden in de volgende aanroep van B<malloc>(), met als "
220 "resultaat dat een geheugen blok van een niet correct grootte zou worden "
221 "toegewezen: "
222
223 #. type: Plain text
224 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
225 #: opensuse-leap-16-1 opensuse-tumbleweed
226 #, no-wrap
227 msgid "malloc(n * size);\n"
228 msgstr "malloc(n * grootte);\n"
229
230 #. type: SS
231 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
232 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
233 #, no-wrap
234 msgid "realloc()"
235 msgstr "realloc()"
236
237 #. type: Plain text
238 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
239 #: opensuse-tumbleweed
240 msgid ""
241 "The B<realloc>() function changes the size of the memory block pointed to "
242 "by I<p> to I<size> bytes. The contents of the memory will be unchanged in "
243 "the range from the start of the region up to the minimum of the old and new "
244 "sizes. If the new size is larger than the old size, the added memory will "
245 "I<not> be initialized."
246 msgstr ""
247 " e B<realloc>() functie verandert de grootte van het geheugen-blok waar "
248 "I<wzr> naar wijst in I<grootte> bytes. De inhoud zal onveranderd blijven in "
249 "het gebied dat begint bij het geheugen gebied tot aan het minimum van de "
250 "oude en nieuwe grootte. Als de nieuwe grootte groter is dan de oude dan "
251 "wordt het toegevoegde geheugen I<niet> geïnitialiseerd. "
252
253 #. type: Plain text
254 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
255 #: opensuse-tumbleweed
256 msgid ""
257 "If I<p> is NULL, then the call is equivalent to I<malloc(size)>, for all "
258 "values of I<size>."
259 msgstr ""
260 "Als I<wzr> NULL is, dan is de aanroep equivalent aan I<malloc(grootte)>, "
261 "voor alle waarden van I<grootte>. "
262
263 #. type: Plain text
264 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
265 #: opensuse-tumbleweed
266 msgid ""
267 "If I<size> is equal to zero, and I<p> is not NULL, then the call is "
268 "equivalent to I<free(p)> (but see \"Nonportable behavior\" for portability "
269 "issues)."
270 msgstr ""
271 "Als I<grootte> gelijk is aan nul, en I<wzr> is niet NULL, dan is de aanroep "
272 "equivalent aan I<free(ptr)> (echter zie \"Niet overdraagbaar gedrag\" voor "
273 "overdraagbaarheid onderwerpen)."
274
275 #. type: Plain text
276 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
277 #: opensuse-tumbleweed
278 msgid ""
279 "Unless I<p> is NULL, it must have been returned by an earlier call to "
280 "B<malloc> or related functions. If the area pointed to was moved, a "
281 "I<free(p)> is done."
282 msgstr ""
283 "Behalve als I<wzr> NULL is, zou het moeten zijn teruggegeven door een "
284 "eerdere aanroep van B<malloc>() of gerelateerde functies. Als het gebied "
285 "waar naar gewezen wordt verplaatst werd dan wordt een I<free(wzr)> "
286 "uitgevoerd. "
287
288 #. type: SS
289 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
290 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
291 #, no-wrap
292 msgid "reallocarray()"
293 msgstr "reallocarray()"
294
295 #. type: Plain text
296 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
297 #: opensuse-tumbleweed
298 msgid ""
299 "The B<reallocarray>() function changes the size of (and possibly moves) "
300 "the memory block pointed to by I<p> to be large enough for an array of I<n> "
301 "elements, each of which is I<size> bytes. It is equivalent to the call"
302 msgstr ""
303 "De B<reallocarray>() functie verandert de grootte van het blok (verplaatst "
304 "dit mogelijk) aangewezen door I<ptr> om groot genoeg te zijn voor een array "
305 "van I<n> elementen, elk met een grootte van I<grootte> bytes. Dit is "
306 "equivalent aan de aanroep:"
307
308 #. type: Plain text
309 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
310 #: opensuse-tumbleweed
311 #, no-wrap
312 msgid "realloc(p, n * size);\n"
313 msgstr "realloc(ptr, n * grootte);\n"
314
315 #. type: Plain text
316 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
317 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
318 msgid ""
319 "However, unlike that B<realloc>() call, B<reallocarray>() fails safely in "
320 "the case where the multiplication would overflow. If such an overflow "
321 "occurs, B<reallocarray>() returns an error."
322 msgstr ""
323 "Echter, anders dan de B<realloc>() aanroep, B<reallocarray>() faalt veilig "
324 "in het geval dat de multiplicatie zou overlopen. Als zo een overloop "
325 "optreed, B<reallocarray>() retourneert een NULL."
326
327 #. type: SH
328 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
329 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
330 #, no-wrap
331 msgid "RETURN VALUE"
332 msgstr "EIND WAARDE"
333
334 #. type: Plain text
335 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
336 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
337 msgid ""
338 "The B<malloc>(), B<calloc>(), B<realloc>(), and B<reallocarray>() functions "
339 "return a pointer to the allocated memory, which is suitably aligned for any "
340 "type that fits into the requested size or less. On error, these functions "
341 "return NULL and set I<errno>. Attempting to allocate more than "
342 "B<PTRDIFF_MAX> bytes is considered an error, as an object that large could "
343 "cause later pointer subtraction to overflow."
344 msgstr ""
345 "De B<malloc>, B<calloc>(), B<realloc>() en B<reallocarry>() functies "
346 "retourneren een wijzer naar het gereserveerde geheugen, dat geschikt is "
347 "opgelijnd voor elk ingebouwd type dat past in de beschikbare ruimte. Bij een "
348 "fout, retourneren deze functies NULL en zetten I<errno>. Proberen te "
349 "reserveren van meer dan B<PTRDIFF_MAX> bytes wordt gezien als een fout, "
350 "omdat een object van deze grootte later kan leiden tot overlopen bij het "
351 "aftrekken van wijzers. "
352
353 #. type: Plain text
354 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
355 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
356 msgid "The B<free>() function returns no value, and preserves I<errno>."
357 msgstr "De B<free>() functie geeft geen waarde terug, en behoudt I<errno>."
358
359 #. type: Plain text
360 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
361 #: opensuse-tumbleweed
362 msgid ""
363 "The B<realloc>() and B<reallocarray>() functions return NULL if I<p> is "
364 "not NULL and the requested size is zero; this is not considered an error. "
365 "(See \"Nonportable behavior\" for portability issues.) Otherwise, the "
366 "returned pointer may be the same as I<p> if the allocation was not moved "
367 "(e.g., there was room to expand the allocation in-place), or different from "
368 "I<p> if the allocation was moved to a new address. If these functions fail, "
369 "the original block is left untouched; it is not freed or moved."
370 msgstr ""
371 "De B<realloc>() en B<reallocarray>() functies retourneren NULL als I<wzr> "
372 "niet NULL en de gevraagde grootte nul is; dit wordt niet beschouwd als een "
373 "fout. (Zie \"Niet overdraagbaar gedrag\" voor overdraagbaarheid "
374 "onderwerpen). De teruggegeven wijzer kan dezelfde zijn als I<wzr> als de "
375 "reservering niet was verplaatst (b.v. er was ruimte om de ruimte uit te "
376 "breiden), of verschillend van I<wzr> als de reservering was verplaatst naar "
377 "een nieuw adres. Als deze functies falen, dan wordt het originele blok niet "
378 "aangetast; het wordt niet verplaatst of vrij gegeven."
379
380 #. type: SH
381 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
382 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
383 #, no-wrap
384 msgid "ERRORS"
385 msgstr "FOUTEN"
386
387 #. type: Plain text
388 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
389 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
390 msgid ""
391 "B<calloc>(), B<malloc>(), B<realloc>(), and B<reallocarray>() can fail with "
392 "the following error:"
393 msgstr ""
394 "B<calloc>(), B<malloc>(), B<realloc>(), en B<reallocarray>() kunnen falen "
395 "met de volgende fout:"
396
397 #. type: TP
398 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
399 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
400 #, no-wrap
401 msgid "B<ENOMEM>"
402 msgstr "B<ENOMEM>"
403
404 #. type: Plain text
405 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
406 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
407 msgid ""
408 "Out of memory. Possibly, the application hit the B<RLIMIT_AS> or "
409 "B<RLIMIT_DATA> limit described in B<getrlimit>(2). Another reason could be "
410 "that the number of mappings created by the caller process exceeded the limit "
411 "specified by I</proc/sys/vm/max_map_count>."
412 msgstr ""
413 "Geen geheugen meer. Mogelijk, het programma bereikte de B<RLIMIT_AS> of "
414 "B<RLIMIT_DATA> limiet beschreven in B<getrlimit>(2). Een andere reden zou "
415 "kunnen zijn dat het aantal mappings die aangemaakt worden door het "
416 "aanroepende proces de limiet zoals aangegeven door I</proc/sys/vm/"
417 "max_map_count> hebben overschreden."
418
419 #. type: SH
420 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
421 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
422 #, no-wrap
423 msgid "ATTRIBUTES"
424 msgstr "ATTRIBUTEN"
425
426 #. type: Plain text
427 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
428 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
429 msgid ""
430 "For an explanation of the terms used in this section, see B<attributes>(7)."
431 msgstr ""
432 "Voor een uitleg van de termen zoals gebruikt in deze sectie, zie "
433 "B<attributen>(7)."
434
435 #. type: tbl table
436 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
437 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
438 #, no-wrap
439 msgid "Interface"
440 msgstr "Interface"
441
442 #. type: tbl table
443 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
444 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
445 #, no-wrap
446 msgid "Attribute"
447 msgstr "Attribuut"
448
449 #. type: tbl table
450 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
451 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
452 #, no-wrap
453 msgid "Value"
454 msgstr "Waarde"
455
456 #. type: tbl table
457 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
458 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
459 #, no-wrap
460 msgid ".na\n"
461 msgstr ".na\n"
462
463 #. type: tbl table
464 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
465 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
466 #, no-wrap
467 msgid ".nh\n"
468 msgstr ".nh\n"
469
470 #. type: tbl table
471 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
472 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
473 #, no-wrap
474 msgid ""
475 "B<malloc>(),\n"
476 "B<free>(),\n"
477 "B<calloc>(),\n"
478 "B<realloc>()"
479 msgstr ""
480 "B<malloc>(),\n"
481 "B<free>(),\n"
482 "B<calloc>(),\n"
483 "B<realloc>()"
484
485 #. type: tbl table
486 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
487 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
488 #, no-wrap
489 msgid "Thread safety"
490 msgstr "Thread veilig"
491
492 #. type: tbl table
493 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
494 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
495 #, no-wrap
496 msgid "MT-Safe"
497 msgstr "MT-Safe"
498
499 #. type: SH
500 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
501 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
502 #, no-wrap
503 msgid "STANDARDS"
504 msgstr "STANDAARDEN"
505
506 #. type: TP
507 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
508 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
509 #, no-wrap
510 msgid "B<malloc>()"
511 msgstr "B<malloc>()"
512
513 #. type: TQ
514 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
515 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
516 #, no-wrap
517 msgid "B<free>()"
518 msgstr "B<free>()"
519
520 #. type: TQ
521 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
522 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
523 #, no-wrap
524 msgid "B<calloc>()"
525 msgstr "B<calloc>()"
526
527 #. type: TQ
528 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
529 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
530 #, no-wrap
531 msgid "B<realloc>()"
532 msgstr "B<realloc>()"
533
534 #. type: Plain text
535 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
536 #: opensuse-tumbleweed
537 msgid "C23, POSIX.1-2024."
538 msgstr "C23, POSIX.1-2024."
539
540 #. type: TP
541 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
542 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
543 #, no-wrap
544 msgid "B<reallocarray>()"
545 msgstr "B<reallocarray>()"
546
547 #. type: Plain text
548 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
549 #: opensuse-tumbleweed
550 msgid "POSIX.1-2024."
551 msgstr "POSIX.1-2024."
552
553 #. type: SS
554 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
555 #: opensuse-tumbleweed
556 #, no-wrap
557 msgid "realloc(p, 0)"
558 msgstr "realloc(p, 0)"
559
560 #. type: Plain text
561 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
562 #: opensuse-tumbleweed
563 msgid ""
564 "The behavior of I<realloc(p,\\ 0)> in glibc doesn't conform to any of C99, "
565 "C11, POSIX.1-2001, POSIX.1-2004, POSIX.1-2008, POSIX.1-2013, POSIX.1-2017, "
566 "or POSIX.1-2024. The C17 specification was changed to make it conforming, "
567 "but that specification made it impossible to write code that reliably "
568 "determines if the input pointer is freed after I<realloc(p,\\ 0)>, and C23 "
569 "changed it again to make this undefined behavior, acknowledging that the C17 "
570 "specification was broad enough, so that undefined behavior wasn't worse than "
571 "that."
572 msgstr ""
573 "Het gedrag van I<realloc(p,\\ 0)> in glibc voldoet niet aan enig van C99, "
574 "C11, POSIX.1-2001, POSIX.1-2004, POSIX.1-2008, POSIX.1-2013, POSIX.1-2017, "
575 "or POSIX.1-2024. De C17 specificatie werd veranderd om het te laten "
576 "voldoen, maar deze specificatie maakte het onmogelijk code te schrijven die "
577 "betrouwbaar bepaald of de input wijzer vrij gegeven wordt na I<realloc(p,\\ "
578 "0)>, en C23 veranderde het nogmaals dor dit tot ongedefinieerd gedrag te "
579 "verklaren, daarbij bekennende dat de C17 specificatie al breed genoeg was "
580 "en dat ongedefinieerd gedrag niet slechter was. "
581
582 #. type: Plain text
583 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
584 #: opensuse-tumbleweed
585 msgid "B<reallocarray>() suffers the same issues in glibc."
586 msgstr "B<reallocarray>() lijdt aan dezelfde dingen in glibc."
587
588 #. type: Plain text
589 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
590 #: opensuse-tumbleweed
591 msgid "musl libc and the BSDs conform to all versions of ISO C and POSIX.1."
592 msgstr "musl libc en de BSDs voldoen aan alle versies van ISO C en POSIX.1."
593
594 #. type: Plain text
595 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
596 #: opensuse-tumbleweed
597 msgid ""
598 "gnulib provides the I<realloc-posix> module, which provides wrappers "
599 "B<realloc>() and B<reallocarray>() that conform to all versions of ISO C "
600 "and POSIX.1."
601 msgstr ""
602 "gnulib voorziet in de I<realloc-posix> module, die voorziet in de "
603 "omwikkelfuncties B<realloc>() en B<reallocarray>() die voldoen aan alle "
604 "versies van ISO C en POSIX.1."
605
606 #. type: Plain text
607 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
608 #: opensuse-tumbleweed
609 msgid ""
610 "There's a proposal to standardize the BSD behavior: E<.UR https:\\://"
611 "www.open-std.org/\\:jtc1/\\:sc22/\\:wg14/\\:www/\\:docs/\\:n3621.txt> "
612 "E<.UE .>"
613 msgstr ""
614 "Er bestaat een voorstel om het BSD gedrag te standaardiseren: E<.UR https:"
615 "\\://www.open-std.org/\\:jtc1/\\:sc22/\\:wg14/\\:www/\\:docs/\\:n3621.txt> "
616 "E<.UE .>"
617
618 #. type: SH
619 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
620 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
621 #, no-wrap
622 msgid "HISTORY"
623 msgstr "HISTORIE"
624
625 #. type: Plain text
626 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
627 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
628 msgid "POSIX.1-2001, C89."
629 msgstr "POSIX.1-2001, C89."
630
631 #. type: Plain text
632 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
633 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
634 msgid "glibc 2.26. OpenBSD 5.6, FreeBSD 11.0."
635 msgstr "glibc 2.26. OpenBSD 5.6, FreeBSD 11.0."
636
637 #. type: Plain text
638 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
639 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
640 msgid ""
641 "B<malloc>() and related functions rejected sizes greater than "
642 "B<PTRDIFF_MAX> starting in glibc 2.30."
643 msgstr ""
644 "B<malloc>() en gerelateerde functies verwerpen groottes groter dan "
645 "B<PTRDIFF_MAX> vanaf glibc 2.30."
646
647 #. type: Plain text
648 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
649 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
650 msgid "B<free>() preserved I<errno> starting in glibc 2.33."
651 msgstr "B<free>() behoudt I<errno> vanaf glibc 2.33."
652
653 #. type: SS
654 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
655 #: opensuse-tumbleweed
656 #, no-wrap
657 msgid "realloc(p,\\ 0)"
658 msgstr "realloc(p,\\ 0)"
659
660 #. type: Plain text
661 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
662 #: opensuse-tumbleweed
663 msgid ""
664 "C89 was ambiguous in its specification of I<realloc(p,\\ 0)>. C99 partially "
665 "fixed this."
666 msgstr ""
667 "C89 was ambigu in de specificatie van I<realloc(p,\\ 0)>. C99 loste dit "
668 "deels op."
669
670 #. type: Plain text
671 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
672 #: opensuse-tumbleweed
673 msgid ""
674 "The original implementation in glibc would have been conforming to C99. "
675 "However, and ironically, trying to comply with C99 before the standard was "
676 "released, glibc changed its behavior in glibc 2.1.1 into something that "
677 "ended up not conforming to the final C99 specification (but this is debated, "
678 "as the wording of the standard seems self-contradicting)."
679 msgstr ""
680 "De originele implementatie in glibc zou hebben voldaan aan C99. Hoewel, en "
681 "ironisch genoeg, terwijl te trachten te voldoen aan C99 vóór de standaard "
682 "werd vrijgegeven, veranderde glibc het gedrag in glibc 2.1.1 naar iets dat "
683 "uiteindelijk niet voldeed aan de finale C99 specificatie (hoewel hierover "
684 "gedebatteerd kan worden omdat de verwoording in de standaard zelf "
685 "tegenstrijdig lijkt)."
686
687 #. type: SH
688 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
689 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
690 #, no-wrap
691 msgid "NOTES"
692 msgstr "OPMERKINGEN"
693
694 #. type: Plain text
695 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
696 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
697 msgid ""
698 "By default, Linux follows an optimistic memory allocation strategy. This "
699 "means that when B<malloc>() returns non-NULL there is no guarantee that the "
700 "memory really is available. In case it turns out that the system is out of "
701 "memory, one or more processes will be killed by the OOM killer. For more "
702 "information, see the description of I</proc/sys/vm/overcommit_memory> and I</"
703 "proc/sys/vm/oom_adj> in B<proc>(5), and the Linux kernel source file "
704 "I<Documentation/vm/overcommit-accounting.rst>."
705 msgstr ""
706 "Standaard volgt, Linux een optimistische geheugen toewijzing strategie. Dit "
707 "betekent dat wanneer B<malloc>() een niet-NULL terug geeft returns dat er "
708 "nog geen garantie is dat het geheugen ook daadwerkelijk beschikbaar is. In "
709 "het geval dat blijkt dat het systeem geen vrij geheugen meer heeft, dan "
710 "worden een of meer processen vernietigd door de OOM vernietiger. Voor meer "
711 "informatie, zie de beschrijving van I</proc/sys/vm/overcommit_memory> en I</"
712 "proc/sys/vm/oom_adj> in B<proc>(5), en het Linux kernel bron code bestand "
713 "and the Linux I<Documentation/vm/overcommit-accounting.rst>."
714
715 #. type: Plain text
716 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
717 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
718 msgid ""
719 "Normally, B<malloc>() allocates memory from the heap, and adjusts the size "
720 "of the heap as required, using B<sbrk>(2). When allocating blocks of memory "
721 "larger than B<MMAP_THRESHOLD> bytes, the glibc B<malloc>() implementation "
722 "allocates the memory as a private anonymous mapping using B<mmap>(2). "
723 "B<MMAP_THRESHOLD> is 128\\ kB by default, but is adjustable using "
724 "B<mallopt>(3). Prior to Linux 4.7 allocations performed using B<mmap>(2) "
725 "were unaffected by the B<RLIMIT_DATA> resource limit; since Linux 4.7, this "
726 "limit is also enforced for allocations performed using B<mmap>(2)."
727 msgstr ""
728 "Normaliter kent B<malloc>() geheugen toe van de heap en past de grootte van "
729 "de heap aan zoals vereist, gebruikmakende van B<sbrk>(2). Bij het toekennen "
730 "van blokken geheugen groter dan B<MMAP_THRESHOLD> bytes kent de glibc "
731 "B<malloc>() implementatie het geheugen toe als een private anoniem tabel met "
732 "behulp van B<mmap>(2). B<MMAP_THRESHOLD> is standaard 128 \\ kB, maar is "
733 "instelbaar m.b.v. B<mallopt>(3). Voor Linux 4.7 werden toekenningen gedaan "
734 "met B<mmap>(2) niet beïnvloed door de B<RLIMIT_DATA> bron limiet; vanaf "
735 "Linux 4.7, wordt deze limiet afgedwongen voor toekenningen gedaan met "
736 "B<mmap>(2)."
737
738 #. type: Plain text
739 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
740 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
741 msgid ""
742 "To avoid corruption in multithreaded applications, mutexes are used "
743 "internally to protect the memory-management data structures employed by "
744 "these functions. In a multithreaded application in which threads "
745 "simultaneously allocate and free memory, there could be contention for these "
746 "mutexes. To scalably handle memory allocation in multithreaded "
747 "applications, glibc creates additional I<memory allocation arenas> if mutex "
748 "contention is detected. Each arena is a large region of memory that is "
749 "internally allocated by the system (using B<brk>(2) or B<mmap>(2)), and "
750 "managed with its own mutexes."
751 msgstr ""
752 "Om corruptie in multi-threaded applicaties te vermijden worden semaforen "
753 "intern gebruikt om geheugen-management data structuren die deze functies "
754 "gebruiken te beschermen. In een multi-threaded application waarin threads "
755 "gelijktijdig geheugen toekennen en vrijgeven kan er een botsing zijn voor "
756 "deze semaforen. Om schaalbaar geheugen toekenning te kunnen afhandelen in "
757 "een multi-threaded applicatie creëert glibc additionele I<memory allocation "
758 "areas> zodra semafoor botsingen worden gedetecteerd. Elk gebied is een grote "
759 "geheugen regio die intern toegekend wordt door het systeem (m.b.v. B<brk>(2) "
760 "of B<mmap>(2)), en bewaakt met zijn eigen semaforen. "
761
762 #. type: Plain text
763 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
764 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
765 msgid ""
766 "If your program uses a private memory allocator, it should do so by "
767 "replacing B<malloc>(), B<free>(), B<calloc>(), and B<realloc>(). The "
768 "replacement functions must implement the documented glibc behaviors, "
769 "including I<errno> handling, size-zero allocations, and overflow checking; "
770 "otherwise, other library routines may crash or operate incorrectly. For "
771 "example, if the replacement I<free>() does not preserve I<errno>, then "
772 "seemingly unrelated library routines may fail without having a valid reason "
773 "in I<errno>. Private memory allocators may also need to replace other glibc "
774 "functions; see \"Replacing malloc\" in the glibc manual for details."
775 msgstr ""
776 "Als uw programma een privé geheugen reservering gebruikt, dan dient het dit "
777 "te doen door vervangen van B<malloc>(), B<free>(), B<calloc>(), en "
778 "B<realloc>(). De vervangings functies moeten het gedocumenteerde glibc "
779 "gedrag, inclusief I<errno> afhandeling, grootte-nul toekenning, en controle "
780 "van overloop implementeren, anders kunnen bibliotheek functies crashen of "
781 "niet correct werken. Bij voorbeeld, als de vervanging van I<free>() I<errno> "
782 "niet behoudt dan kunnen ogenschijnlijk niet gerelateerde bibliotheek "
783 "functie falen zonder een geldige reden in I<errno>. Privé geheugen "
784 "reserveringen kunnen ook andere glibc functies vervangen; zie \"Vervangen "
785 "van malloc\" in de glibc handleiding voor details."
786
787 #. type: Plain text
788 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
789 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
790 msgid ""
791 "Crashes in memory allocators are almost always related to heap corruption, "
792 "such as overflowing an allocated chunk or freeing the same pointer twice."
793 msgstr ""
794 "Crashes in bij het toewijzen van geheugen zijn bijna altijd gerelateerd aan "
795 "corruptie van de heap, zoals overlopen van een toegekend gebied or twee keer "
796 "vrij geven van dezelfde wijzer."
797
798 #. type: Plain text
799 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
800 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
801 msgid ""
802 "The B<malloc>() implementation is tunable via environment variables; see "
803 "B<mallopt>(3) for details."
804 msgstr ""
805 "De B<malloc>() implementatie is aanpasbaar via omgeving variabelen; zie "
806 "B<mallopt>(3) voor details."
807
808 #. type: SS
809 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
810 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
811 #, no-wrap
812 msgid "Nonportable behavior"
813 msgstr "Niet overdraagbaar gedrag"
814
815 #. type: Plain text
816 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
817 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
818 msgid ""
819 "The behavior of these functions when the requested size is zero is glibc "
820 "specific; other implementations may return NULL without setting I<errno>, "
821 "and portable POSIX programs should tolerate such behavior. See "
822 "B<realloc>(3p)."
823 msgstr ""
824 "Het gedrag van deze functies wanneer de gevraagde grootte nul is, is glibc "
825 "afhankelijk; andere implementaties kunnen NULL teruggeven zonder I<errno> te "
826 "zetten. Overdraagbare POSIX programma´s moeten dit gedrag tolereren. Zie "
827 "B<realloc>(3p)."
828
829 #. type: Plain text
830 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
831 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
832 msgid ""
833 "POSIX requires memory allocators to set I<errno> upon failure. However, the "
834 "C standard does not require this, and applications portable to non-POSIX "
835 "platforms should not assume this."
836 msgstr ""
837 "POSIX vereist dat geheugen toewijzingen op I<errno> worden gezet bij een "
838 "fout. Hoewel de C standaard dat niet vereist, en applicaties die overgezet "
839 "worden naar niet-POSIX platformen moeten hier niet van uit gaan."
840
841 #. type: Plain text
842 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
843 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
844 msgid ""
845 "Portable programs should not use private memory allocators, as POSIX and the "
846 "C standard do not allow replacement of B<malloc>(), B<free>(), B<calloc>(), "
847 "and B<realloc>()."
848 msgstr ""
849 "Overdraagbare programma´s moeten geen privé geheugen reserveringen "
850 "gebruiken, omdat POSIX en de C standaard geen vervanging van B<malloc>(), "
851 "B<free>(), B<calloc>(), en B<realloc>() toestaan."
852
853 #. type: SH
854 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
855 #: opensuse-tumbleweed
856 #, no-wrap
857 msgid "BUGS"
858 msgstr "BUGS"
859
860 #. type: Plain text
861 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
862 #: opensuse-tumbleweed
863 msgid ""
864 "Programmers would naturally expect by induction that I<\\%realloc(p,\\ "
865 "size)> is consistent with I<free(p)> and I<malloc(size)>, as that is the "
866 "behavior in the general case. This is not explicitly required by "
867 "POSIX.1-2024 or C11, but all conforming implementations are consistent with "
868 "that."
869 msgstr ""
870 "Programmeurs zouden natuurlijk verwachten bij inductie dat I<\\%realloc(p,"
871 "\\ size)> consistent is met I<free(p)> en I<malloc(size)>, omdat dat het "
872 "algemene gedrag is. Dit wordt niet expliciet vereist in POSIX.1-2024 of C11, "
873 "maar alle implementaties zijn hiermee consistent. "
874
875 #. type: Plain text
876 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
877 #: opensuse-tumbleweed
878 msgid ""
879 "The glibc implementation of B<realloc>() is not consistent with that, and "
880 "as a consequence, it is dangerous to call I<\\%realloc(p,\\ 0)> in glibc."
881 msgstr ""
882 "De glibc implementatie van B<realloc>() is niet consistent met deze, met "
883 "de consequentie dat het gevaarlijk is om I<\\%realloc(p,\\ 0)> in glibc aan "
884 "te roepen."
885
886 #. type: Plain text
887 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
888 #: opensuse-tumbleweed
889 msgid ""
890 "A trivial workaround for glibc is calling it as I<\\%realloc(p,\\ size?"
891 "size:1)>."
892 msgstr ""
893 "Een triviale tijdelijke oplossing voor glibc is door I<\\%realloc(p,\\ size?"
894 "size:1)> aan te roepen."
895
896 #. type: Plain text
897 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
898 #: opensuse-tumbleweed
899 msgid ""
900 "The workaround for B<reallocarray>() in glibc \\[em]which shares the same "
901 "bug\\[em] would be I<\\%reallocarray(p,\\ n?n:1,\\ size?size:1)>."
902 msgstr ""
903 "De tijdelijke oplossing voor B<reallocarray>() in glibc \\[em] die dezelfde "
904 "bug heeft als bug\\[em] zou I<\\%reallocarray(p,\\ n?n:1,\\ size?size:1)> "
905 "zijn."
906
907 #. type: SH
908 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
909 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
910 #, no-wrap
911 msgid "EXAMPLES"
912 msgstr "VOORBEELDEN"
913
914 #. type: Plain text
915 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
916 #: opensuse-leap-16-1 opensuse-tumbleweed
917 #, no-wrap
918 msgid ""
919 "#include E<lt>err.hE<gt>\n"
920 "#include E<lt>stddef.hE<gt>\n"
921 "#include E<lt>stdio.hE<gt>\n"
922 "#include E<lt>stdlib.hE<gt>\n"
923 "#include E<lt>string.hE<gt>\n"
924 "\\&\n"
925 "#define MALLOCARRAY(n, type) ((type *) my_mallocarray(n, sizeof(type)))\n"
926 "#define MALLOC(type) MALLOCARRAY(1, type)\n"
927 "\\&\n"
928 "static inline void *my_mallocarray(size_t n, size_t size);\n"
929 "\\&\n"
930 "int\n"
931 "main(void)\n"
932 "{\n"
933 " char *p;\n"
934 "\\&\n"
935 " p = MALLOCARRAY(32, char);\n"
936 " if (p == NULL)\n"
937 " err(EXIT_FAILURE, \"malloc\");\n"
938 "\\&\n"
939 " strlcpy(p, \"foo\", 32);\n"
940 " puts(p);\n"
941 "}\n"
942 "\\&\n"
943 "static inline void *\n"
944 "my_mallocarray(size_t n, size_t size)\n"
945 "{\n"
946 " return reallocarray(NULL, n, size);\n"
947 "}\n"
948 msgstr ""
949 "#include E<lt>err.hE<gt>\n"
950 "#include E<lt>stddef.hE<gt>\n"
951 "#include E<lt>stdio.hE<gt>\n"
952 "#include E<lt>stdlib.hE<gt>\n"
953 "#include E<lt>string.hE<gt>\n"
954 "\\&\n"
955 "#define MALLOCARRAY(n, type) ((type *) my_mallocarray(n, sizeof(type)))\n"
956 "#define MALLOC(type) MALLOCARRAY(1, type)\n"
957 "\\&\n"
958 "static inline void *my_mallocarray(size_t n, size_t size);\n"
959 "\\&\n"
960 "int\n"
961 "main(void)\n"
962 "{\n"
963 " char *p;\n"
964 "\\&\n"
965 " p = MALLOCARRAY(32, char);\n"
966 " if (p == NULL)\n"
967 " err(EXIT_FAILURE, \"malloc\");\n"
968 "\\&\n"
969 " strlcpy(p, \"foo\", 32);\n"
970 " puts(p);\n"
971 "}\n"
972 "\\&\n"
973 "static inline void *\n"
974 "my_mallocarray(size_t nmemb, size_t size)\n"
975 "{\n"
976 " return reallocarray(NULL, nmemb, size);\n"
977 "}\n"
978
979 #. type: SH
980 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
981 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
982 #, no-wrap
983 msgid "SEE ALSO"
984 msgstr "ZIE OOK"
985
986 #. type: Plain text
987 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
988 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
989 msgid ""
990 "B<valgrind>(1), B<brk>(2), B<mmap>(2), B<alloca>(3), B<malloc_get_state>(3), "
991 "B<malloc_info>(3), B<malloc_trim>(3), B<malloc_usable_size>(3), "
992 "B<mallopt>(3), B<mcheck>(3), B<mtrace>(3), B<posix_memalign>(3)"
993 msgstr ""
994 "B<valgrind>(1), B<brk>(2), B<mmap>(2), B<alloca>(3), B<malloc_get_state>(3), "
995 "B<malloc_info>(3), B<malloc_trim>(3), B<malloc_usable_size>(3), "
996 "B<mallopt>(3), B<mcheck>(3), B<mtrace>(3), B<posix_memalign>(3)"
997
998 #. type: Plain text
999 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
1000 #: opensuse-tumbleweed
1001 msgid ""
1002 "For details of the GNU C library implementation, see E<.UR https:\\://"
1003 "sourceware.org/glibc/wiki/MallocInternals> E<.UE .>"
1004 msgstr ""
1005 "Voor details over de GNU C library implementatie, zie E<.UR https:\\://"
1006 "sourceware.org/glibc/wiki/MallocInternals> E<.UE .>"
1007
1008 #. type: TH
1009 #: debian-trixie
1010 #, no-wrap
1011 msgid "2024-05-02"
1012 msgstr "2 mei 2024"
1013
1014 #. type: TH
1015 #: debian-trixie
1016 #, no-wrap
1017 msgid "Linux man-pages 6.9.1"
1018 msgstr "Linux man-paginas 6.9.1"
1019
1020 #. type: Plain text
1021 #: debian-trixie
1022 msgid "Standard C library (I<libc>, I<-lc>)"
1023 msgstr "Standaard C bibliotheek (I<libc>, I<-lc>)"
1024
1025 #. type: Plain text
1026 #: debian-trixie
1027 #, no-wrap
1028 msgid ""
1029 "B<void *malloc(size_t >I<size>B<);>\n"
1030 "B<void free(void *_Nullable >I<ptr>B<);>\n"
1031 "B<void *calloc(size_t >I<nmemb>B<, size_t >I<size>B<);>\n"
1032 "B<void *realloc(void *_Nullable >I<ptr>B<, size_t >I<size>B<);>\n"
1033 "B<void *reallocarray(void *_Nullable >I<ptr>B<, size_t >I<nmemb>B<, size_t >I<size>B<);>\n"
1034 msgstr ""
1035 "B<void *malloc(size_t >I<size>B<);>\n"
1036 "B<void free(void *_Nullable >I<ptr>B<);>\n"
1037 "B<void *calloc(size_t >I<nmemb>B<, size_t >I<size>B<);>\n"
1038 "B<void *realloc(void *_Nullable >I<ptr>B<, size_t >I<size>B<);>\n"
1039 "B<void *reallocarray(void *_Nullable >I<ptr>B<, size_t >I<nmemb>B<, size_t >I<size>B<);>\n"
1040
1041 #. type: Plain text
1042 #: debian-trixie fedora-44 fedora-rawhide
1043 msgid ""
1044 "The B<free>() function frees the memory space pointed to by I<ptr>, which "
1045 "must have been returned by a previous call to B<malloc>() or related "
1046 "functions. Otherwise, or if I<ptr> has already been freed, undefined "
1047 "behavior occurs. If I<ptr> is NULL, no operation is performed."
1048 msgstr ""
1049 "De B<free>() functie geeft de geheugen-ruimte waar I<wzr> naar wijst vrij, "
1050 "geheugen dat gereserveerd moet zijn door een eerdere aanroep naar "
1051 "B<malloc>() of gerelateerde functies. Anders, of als I<free(wzr)> al eerder "
1052 "werd aangeroepen, ontstaat onbepaald gedrag. Als I<wzr> B<NULL> is wordt "
1053 "niets gedaan."
1054
1055 #. type: Plain text
1056 #: debian-trixie
1057 msgid ""
1058 "The B<calloc>() function allocates memory for an array of I<nmemb> elements "
1059 "of I<size> bytes each and returns a pointer to the allocated memory. The "
1060 "memory is set to zero. If I<nmemb> or I<size> is 0, then B<calloc>() "
1061 "returns a unique pointer value that can later be successfully passed to "
1062 "B<free>()."
1063 msgstr ""
1064 "De B<calloc>() functie reserveert I<grootte> bytes geheugen en geeft een "
1065 "wijzer naar het gereserveerde geheugen terug. Het geheugen wordt met nul "
1066 "geïnitialiseerd. Als I<nmemb> of I<grootte> gelijk is aan 0, dan retourneert "
1067 "B<calloc>() een unieke wijzer waarde die later succesvol kan worden mee "
1068 "gegeven aan B<free>()."
1069
1070 #. type: Plain text
1071 #: debian-trixie
1072 msgid ""
1073 "If the multiplication of I<nmemb> and I<size> would result in integer "
1074 "overflow, then B<calloc>() returns an error. By contrast, an integer "
1075 "overflow would not be detected in the following call to B<malloc>(), with "
1076 "the result that an incorrectly sized block of memory would be allocated:"
1077 msgstr ""
1078 "Als de multiplicatie van I<nmemb> en I<grootte> zou resulteren in het "
1079 "overlopen van een geheel getal, dan geeft B<calloc>() een fout terug. In "
1080 "tegenstelling daarmee, zou het overlopen van een geheel getal niet "
1081 "gedetecteerd worden in de volgende aanroep van B<malloc>(), met als "
1082 "resultaat dat een geheugen blok van niet correct grootte zou worden "
1083 "toegewezen: "
1084
1085 #. type: Plain text
1086 #: debian-trixie
1087 #, no-wrap
1088 msgid "malloc(nmemb * size);\n"
1089 msgstr "malloc(nmemb * grootte);\n"
1090
1091 #. type: Plain text
1092 #: debian-trixie fedora-44 fedora-rawhide
1093 msgid ""
1094 "The B<realloc>() function changes the size of the memory block pointed to "
1095 "by I<ptr> to I<size> bytes. The contents of the memory will be unchanged in "
1096 "the range from the start of the region up to the minimum of the old and new "
1097 "sizes. If the new size is larger than the old size, the added memory will "
1098 "I<not> be initialized."
1099 msgstr ""
1100 "De B<realloc>() functie verandert de grootte van het geheugen-blok waar "
1101 "I<wzr> naar wijst in I<grootte> bytes. De inhoud zal onveranderd blijven in "
1102 "het gebied dat begint bij het geheugen gebied tot aan het minimum van de "
1103 "oude en nieuwe grootte. Als de nieuwe grootte groter is dan de oude dan "
1104 "wordt het toegevoegde geheugen I<niet> geïnitialiseerd. "
1105
1106 #. type: Plain text
1107 #: debian-trixie fedora-44 fedora-rawhide
1108 msgid ""
1109 "If I<ptr> is NULL, then the call is equivalent to I<malloc(size)>, for all "
1110 "values of I<size>."
1111 msgstr ""
1112 "Als I<wzr> NULL is, dan is de aanroep equivalent aan I<malloc(grootte)>, "
1113 "voor alle waarden van I<grootte>."
1114
1115 #. type: Plain text
1116 #: debian-trixie fedora-44 fedora-rawhide
1117 msgid ""
1118 "If I<size> is equal to zero, and I<ptr> is not NULL, then the call is "
1119 "equivalent to I<free(ptr)> (but see \"Nonportable behavior\" for portability "
1120 "issues)."
1121 msgstr ""
1122 "Als I<grootte> gelijk is aan nul, en I<wzr> is niet NULL, dan is de aanroep "
1123 "equivalent aan I<free(ptr)> (echter zie \"Niet overdraagbaar gedrag\" voor "
1124 "overdraagbaarheid onderwerpen)."
1125
1126 #. type: Plain text
1127 #: debian-trixie fedora-44 fedora-rawhide
1128 msgid ""
1129 "Unless I<ptr> is NULL, it must have been returned by an earlier call to "
1130 "B<malloc> or related functions. If the area pointed to was moved, a "
1131 "I<free(ptr)> is done."
1132 msgstr ""
1133 "Behalve als I<wzr> NULL is, zou het moeten zijn teruggegeven door een "
1134 "eerdere aanroep van B<malloc>() of gerelateerde functies. Als het gebied "
1135 "waar naar gewezen wordt verplaatst werd dan werd een I<free(wzr)> uitgevoerd."
1136
1137 #. type: Plain text
1138 #: debian-trixie
1139 msgid ""
1140 "The B<reallocarray>() function changes the size of (and possibly moves) "
1141 "the memory block pointed to by I<ptr> to be large enough for an array of "
1142 "I<nmemb> elements, each of which is I<size> bytes. It is equivalent to the "
1143 "call"
1144 msgstr ""
1145 "De B<reallocarray>() functie verandert de grootte van het blok (verplaatst "
1146 "dit mogelijk) aangewezen door I<ptr> om groot genoeg te zijn voor een tabel "
1147 "van I<nmemb> elementen, elk met een grootte van I<grootte> bytes. Dit is "
1148 "equivalent aan de aanroep:"
1149
1150 #. type: Plain text
1151 #: debian-trixie
1152 #, no-wrap
1153 msgid "realloc(ptr, nmemb * size);\n"
1154 msgstr "realloc(ptr, nmemb * grootte);\n"
1155
1156 #. type: Plain text
1157 #: debian-trixie fedora-44 fedora-rawhide
1158 msgid ""
1159 "The B<realloc>() and B<reallocarray>() functions return NULL if I<ptr> is "
1160 "not NULL and the requested size is zero; this is not considered an error. "
1161 "(See \"Nonportable behavior\" for portability issues.) Otherwise, the "
1162 "returned pointer may be the same as I<ptr> if the allocation was not moved "
1163 "(e.g., there was room to expand the allocation in-place), or different from "
1164 "I<ptr> if the allocation was moved to a new address. If these functions "
1165 "fail, the original block is left untouched; it is not freed or moved."
1166 msgstr ""
1167 "De B<realloc>() en B<reallocarray>() functies retourneren een wijzer naar "
1168 "het nieuw gereserveerde geheugen, dat geschikt is opgelijnd voor elk "
1169 "ingebouwd type of NULL als de I<wzr> niet NULL is en de gevraagde grootte "
1170 "nul is. (Zie \"Niet overdraagbaar gedrag\" voor overdraagbaarheids "
1171 "onderwerpen). dDe teruggegeven wijzer kan dezelfde zijn als I<wzr> als de "
1172 "reservering niet was verplaatst (b.v. er was ruimte om de ruimte uit te "
1173 "breiden), of verschillend van I<wzr> als de reservering was verplaatst naar "
1174 "een nieuw adres. Als deze functies falen, dan wordt het originele blok niet "
1175 "aangetast; het wordt niet verplaatst of vrij gegeven."
1176
1177 #. type: Plain text
1178 #: debian-trixie fedora-44 fedora-rawhide
1179 msgid "C11, POSIX.1-2008."
1180 msgstr "C11, POSIX.1-2008."
1181
1182 #. type: Plain text
1183 #: debian-trixie fedora-44 fedora-rawhide
1184 msgid "None."
1185 msgstr "Geen."
1186
1187 #. type: Plain text
1188 #: debian-trixie
1189 #, no-wrap
1190 msgid ""
1191 "#include E<lt>err.hE<gt>\n"
1192 "#include E<lt>stddef.hE<gt>\n"
1193 "#include E<lt>stdio.hE<gt>\n"
1194 "#include E<lt>stdlib.hE<gt>\n"
1195 "#include E<lt>string.hE<gt>\n"
1196 "\\&\n"
1197 "#define MALLOCARRAY(n, type) ((type *) my_mallocarray(n, sizeof(type)))\n"
1198 "#define MALLOC(type) MALLOCARRAY(1, type)\n"
1199 "\\&\n"
1200 "static inline void *my_mallocarray(size_t nmemb, size_t size);\n"
1201 "\\&\n"
1202 "int\n"
1203 "main(void)\n"
1204 "{\n"
1205 " char *p;\n"
1206 "\\&\n"
1207 " p = MALLOCARRAY(32, char);\n"
1208 " if (p == NULL)\n"
1209 " err(EXIT_FAILURE, \"malloc\");\n"
1210 "\\&\n"
1211 " strlcpy(p, \"foo\", 32);\n"
1212 " puts(p);\n"
1213 "}\n"
1214 "\\&\n"
1215 "static inline void *\n"
1216 "my_mallocarray(size_t nmemb, size_t size)\n"
1217 "{\n"
1218 " return reallocarray(NULL, nmemb, size);\n"
1219 "}\n"
1220 msgstr ""
1221 "#include E<lt>err.hE<gt>\n"
1222 "#include E<lt>stddef.hE<gt>\n"
1223 "#include E<lt>stdio.hE<gt>\n"
1224 "#include E<lt>stdlib.hE<gt>\n"
1225 "#include E<lt>string.hE<gt>\n"
1226 "\\&\n"
1227 "#define MALLOCARRAY(n, type) ((type *) my_mallocarray(n, sizeof(type)))\n"
1228 "#define MALLOC(type) MALLOCARRAY(1, type)\n"
1229 "\\&\n"
1230 "static inline void *my_mallocarray(size_t nmemb, size_t size);\n"
1231 "\\&\n"
1232 "int\n"
1233 "main(void)\n"
1234 "{\n"
1235 " char *p;\n"
1236 "\\&\n"
1237 " p = MALLOCARRAY(32, char);\n"
1238 " if (p == NULL)\n"
1239 " err(EXIT_FAILURE, \"malloc\");\n"
1240 "\\&\n"
1241 " strlcpy(p, \"foo\", 32);\n"
1242 " puts(p);\n"
1243 "}\n"
1244 "\\&\n"
1245 "static inline void *\n"
1246 "my_mallocarray(size_t nmemb, size_t size)\n"
1247 "{\n"
1248 " return reallocarray(NULL, nmemb, size);\n"
1249 "}\n"
1250
1251 #. type: Plain text
1252 #: debian-trixie fedora-44 fedora-rawhide
1253 msgid ""
1254 "For details of the GNU C library implementation, see E<.UR https://"
1255 "sourceware.org/glibc/wiki/MallocInternals> E<.UE .>"
1256 msgstr ""
1257 "Voor details over de GNU C library implementatie, zie E<.UR https://"
1258 "sourceware.org/glibc/wiki/MallocInternals> E<.UE .>"
1259
1260 #. type: TH
1261 #: fedora-44 fedora-rawhide
1262 #, no-wrap
1263 msgid "2024-11-17"
1264 msgstr "17 november 2024"
1265
1266 #. type: TH
1267 #: fedora-44 fedora-rawhide
1268 #, no-wrap
1269 msgid "Linux man-pages 6.13"
1270 msgstr "Linux man-paginas 6.13"
1271
1272 #. type: Plain text
1273 #: fedora-44 fedora-rawhide
1274 #, no-wrap
1275 msgid ""
1276 "B<void *malloc(size_t >I<size>B<);>\n"
1277 "B<void free(void *_Nullable >I<ptr>B<);>\n"
1278 "B<void *calloc(size_t >I<n>B<, size_t >I<size>B<);>\n"
1279 "B<void *realloc(void *_Nullable >I<ptr>B<, size_t >I<size>B<);>\n"
1280 "B<void *reallocarray(void *_Nullable >I<ptr>B<, size_t >I<n>B<, size_t >I<size>B<);>\n"
1281 msgstr ""
1282 "B<void *malloc(size_t >I<size>B<);>\n"
1283 "B<void free(void *_Nullable >I<ptr>B<);>\n"
1284 "B<void *calloc(size_t >I<n>B<, size_t >I<size>B<);>\n"
1285 "B<void *realloc(void *_Nullable >I<ptr>B<, size_t >I<size>B<);>\n"
1286 "B<void *reallocarray(void *_Nullable >I<ptr>B<, size_t >I<n>B<, size_t >I<size>B<);>\n"
1287
1288 #. type: Plain text
1289 #: fedora-44 fedora-rawhide
1290 msgid ""
1291 "The B<reallocarray>() function changes the size of (and possibly moves) "
1292 "the memory block pointed to by I<ptr> to be large enough for an array of "
1293 "I<n> elements, each of which is I<size> bytes. It is equivalent to the call"
1294 msgstr ""
1295 "De B<reallocarray>() functie verandert de grootte van het blok (verplaatst "
1296 "dit mogelijk) aangewezen door I<ptr> om groot genoeg te zijn voor een tabel "
1297 "van I<n> elementen, elk met een grootte van I<grootte> bytes. Dit is "
1298 "equivalent aan de aanroep:"
1299
1300 #. type: Plain text
1301 #: fedora-44 fedora-rawhide
1302 #, no-wrap
1303 msgid "realloc(ptr, n * size);\n"
1304 msgstr "realloc(ptr, n * grootte);\n"
1305
1306 #. type: TH
1307 #: mageia-cauldron
1308 #, no-wrap
1309 msgid "Linux man-pages 6.17"
1310 msgstr "Linux man-paginas 6.17"
1311
1312 #. type: TH
1313 #: opensuse-leap-16-1 opensuse-tumbleweed
1314 #, no-wrap
1315 msgid "Linux man-pages (unreleased)"
1316 msgstr "Linux man-paginas (niet vrijgegeven)"