Debian Codegraph @

po/ru/man3/strcpy.3.po

raw
1 # Russian translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # Alexander Golubev <[email protected]>, 2018.
5 # Azamat Hackimov <[email protected]>, 2011, 2014-2016.
6 # Hotellook, 2014.
7 # Nikita <[email protected]>, 2014.
8 # Spiros Georgaras <[email protected]>, 2016.
9 # Vladislav <[email protected]>, 2015.
10 # Yuri Kozlov <[email protected]>, 2011-2019.
11 # Иван Павлов <[email protected]>, 2017.
12 msgid ""
13 msgstr ""
14 "Project-Id-Version: manpages-l10n\n"
15 "POT-Creation-Date: 2026-06-05 06:45+0200\n"
16 "PO-Revision-Date: 2024-12-21 19:50+0300\n"
17 "Last-Translator: Yuri Kozlov <[email protected]>\n"
18 "Language-Team: Russian <[email protected]>\n"
19 "Language: ru\n"
20 "MIME-Version: 1.0\n"
21 "Content-Type: text/plain; charset=UTF-8\n"
22 "Content-Transfer-Encoding: 8bit\n"
23 "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
24 "n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || "
25 "(n%100>=11 && n%100<=14)? 2 : 3);\n"
26 "X-Generator: Lokalize 2.0\n"
27
28 #. type: TH
29 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
30 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
31 #, no-wrap
32 msgid "strcpy"
33 msgstr ""
34
35 #. type: TH
36 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
37 #, no-wrap
38 msgid "2026-02-25"
39 msgstr "25 февраля 2026 г."
40
41 #. type: TH
42 #: archlinux debian-unstable
43 #, fuzzy, no-wrap
44 #| msgid "Linux man-pages 6.17"
45 msgid "Linux man-pages 6.18"
46 msgstr "Справочные страницы Linux 6.17"
47
48 #. type: SH
49 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
50 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
51 #, no-wrap
52 msgid "NAME"
53 msgstr "НАИМЕНОВАНИЕ"
54
55 #. type: Plain text
56 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
57 #, fuzzy
58 #| msgid "strcpy, strncpy - copy a string"
59 msgid "strcpy, strcat - copy or catenate a string"
60 msgstr "strcpy, strncpy - копирование строки"
61
62 #. type: SH
63 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
64 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
65 #, no-wrap
66 msgid "LIBRARY"
67 msgstr "БИБЛИОТЕКА"
68
69 #. type: Plain text
70 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
71 #: opensuse-leap-16-1 opensuse-tumbleweed
72 msgid "Standard C library (I<libc>,\\ I<-lc>)"
73 msgstr "Стандартная библиотека языка C (I<libc>,\\ I<-lc>)"
74
75 #. type: SH
76 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
77 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
78 #, no-wrap
79 msgid "SYNOPSIS"
80 msgstr "СИНТАКСИС"
81
82 #. type: Plain text
83 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
84 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
85 #, no-wrap
86 msgid "B<#include E<lt>string.hE<gt>>\n"
87 msgstr "B<#include E<lt>string.hE<gt>>\n"
88
89 #. type: Plain text
90 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
91 #, fuzzy, no-wrap
92 #| msgid ""
93 #| "B<char *strndup(const char *>I<s>B<, size_t >I<n>B<);>\n"
94 #| "B<char *strdupa(const char *>I<s>B<);>\n"
95 #| "B<char *strndupa(const char *>I<s>B<, size_t >I<n>B<);>\n"
96 msgid ""
97 "B<char *strcpy(char *restrict >I<dst>B<, const char *restrict >I<src>B<);>\n"
98 "B<char *strcat(char *restrict >I<dst>B<, const char *restrict >I<src>B<);>\n"
99 msgstr ""
100 "B<char *strndup(const char *>I<s>B<, size_t >I<n>B<);>\n"
101 "B<char *strdupa(const char *>I<s>B<);>\n"
102 "B<char *strndupa(const char *>I<s>B<, size_t >I<n>B<);>\n"
103
104 #. type: SH
105 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
106 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
107 #, no-wrap
108 msgid "DESCRIPTION"
109 msgstr "ОПИСАНИЕ"
110
111 #. type: TP
112 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
113 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
114 #, fuzzy, no-wrap
115 #| msgid "B<strncpy>(3)"
116 msgid "B<strcpy>()"
117 msgstr "B<strncpy>(3)"
118
119 #. type: Plain text
120 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
121 msgid ""
122 "This function copies the string pointed to by I<src>, into a string at the "
123 "buffer pointed to by I<dst>. The programmer is responsible for allocating a "
124 "destination buffer large enough, that is, I<strlen(src) + 1>."
125 msgstr ""
126
127 #. type: Plain text
128 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
129 #, fuzzy
130 #| msgid "is equivalent to"
131 msgid "It is equivalent to"
132 msgstr "равнозначно"
133
134 #. type: Plain text
135 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
136 #, no-wrap
137 msgid "stpcpy(dst, src), dst\n"
138 msgstr ""
139
140 #. #-#-#-#-# archlinux: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
141 #. type: TP
142 #. #-#-#-#-# debian-trixie: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
143 #. type: TQ
144 #. #-#-#-#-# debian-unstable: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
145 #. type: TP
146 #. #-#-#-#-# fedora-44: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
147 #. type: TQ
148 #. #-#-#-#-# fedora-rawhide: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
149 #. type: TQ
150 #. #-#-#-#-# mageia-cauldron: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
151 #. type: TQ
152 #. #-#-#-#-# opensuse-leap-16-1: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
153 #. type: TP
154 #. #-#-#-#-# opensuse-tumbleweed: strcpy.3.pot (PACKAGE VERSION) #-#-#-#-#
155 #. type: TP
156 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
157 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
158 #, fuzzy, no-wrap
159 #| msgid "B<stat>(2)"
160 msgid "B<strcat>()"
161 msgstr "B<stat>(2)"
162
163 #. type: Plain text
164 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
165 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
166 msgid ""
167 "This function catenates the string pointed to by I<src>, after the string "
168 "pointed to by I<dst> (overwriting its terminating null byte). The "
169 "programmer is responsible for allocating a destination buffer large enough, "
170 "that is, I<strlen(dst) + strlen(src) + 1>."
171 msgstr ""
172
173 #. type: Plain text
174 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
175 #, no-wrap
176 msgid "stpcpy(strnul(dst), src), dst\n"
177 msgstr ""
178
179 #. type: SH
180 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
181 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
182 #, no-wrap
183 msgid "RETURN VALUE"
184 msgstr "ВОЗВРАЩАЕМОЕ ЗНАЧЕНИЕ"
185
186 #. type: Plain text
187 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
188 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
189 #, fuzzy
190 #| msgid "These functions do not return a value."
191 msgid "These functions return I<dst>."
192 msgstr "Данные функции не возвращают никаких значений."
193
194 #. type: SH
195 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
196 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
197 #, no-wrap
198 msgid "ATTRIBUTES"
199 msgstr "АТРИБУТЫ"
200
201 #. type: Plain text
202 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
203 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
204 msgid ""
205 "For an explanation of the terms used in this section, see B<attributes>(7)."
206 msgstr "Описание терминов данного раздела смотрите в B<attributes>(7)."
207
208 #. type: tbl table
209 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
210 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
211 #, no-wrap
212 msgid "Interface"
213 msgstr "Интерфейс"
214
215 #. type: tbl table
216 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
217 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
218 #, no-wrap
219 msgid "Attribute"
220 msgstr "Атрибут"
221
222 #. type: tbl table
223 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
224 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
225 #, no-wrap
226 msgid "Value"
227 msgstr "Значение"
228
229 #. type: tbl table
230 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
231 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
232 #, no-wrap
233 msgid ".na\n"
234 msgstr ".na\n"
235
236 #. type: tbl table
237 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
238 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
239 #, no-wrap
240 msgid ".nh\n"
241 msgstr ".nh\n"
242
243 #. type: tbl table
244 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
245 #, fuzzy, no-wrap
246 #| msgid ""
247 #| "B<strcpy>(),\n"
248 #| "B<strncpy>()"
249 msgid ""
250 "B<strcpy>(),\n"
251 "B<strcat>()"
252 msgstr ""
253 "B<strcpy>(),\n"
254 "B<strncpy>()"
255
256 #. type: tbl table
257 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
258 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
259 #, no-wrap
260 msgid "Thread safety"
261 msgstr "Безвредность в нитях"
262
263 #. type: tbl table
264 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
265 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
266 #, no-wrap
267 msgid "MT-Safe"
268 msgstr "MT-Safe"
269
270 #. type: SH
271 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
272 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
273 #, no-wrap
274 msgid "STANDARDS"
275 msgstr "СТАНДАРТЫ"
276
277 #. type: Plain text
278 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
279 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
280 msgid "C11, POSIX.1-2008."
281 msgstr "C11, POSIX.1-2008."
282
283 #. type: SH
284 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
285 #, no-wrap
286 msgid "HISTORY"
287 msgstr "ИСТОРИЯ"
288
289 #. type: Plain text
290 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
291 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
292 msgid "POSIX.1-2001, C89, SVr4, 4.3BSD."
293 msgstr "POSIX.1-2001, C89, SVr4, 4.3BSD."
294
295 #. type: SH
296 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
297 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
298 #, no-wrap
299 msgid "CAVEATS"
300 msgstr ""
301
302 #. type: Plain text
303 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
304 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
305 #, fuzzy
306 #| msgid "The strings may not overlap."
307 msgid "The strings I<src> and I<dst> may not overlap."
308 msgstr "Строки не должны пересекаться."
309
310 #. type: Plain text
311 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
312 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
313 msgid ""
314 "If the destination buffer is not large enough, the behavior is undefined. "
315 "See B<_FORTIFY_SOURCE> in B<feature_test_macros>(7)."
316 msgstr ""
317
318 #. type: Plain text
319 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
320 #: opensuse-tumbleweed
321 msgid ""
322 "B<strcat>() can be very inefficient. Read about E<.UR https:\\://"
323 "www.joelonsoftware.com/\\:2001/12/11/\\:back-to-basics/> Shlemiel the "
324 "painter E<.UE .>"
325 msgstr ""
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 "EXAMPLES"
332 msgstr "ПРИМЕРЫ"
333
334 #. type: Plain text
335 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
336 #, no-wrap
337 msgid ""
338 "#include E<lt>err.hE<gt>\n"
339 "#include E<lt>stdio.hE<gt>\n"
340 "#include E<lt>stdlib.hE<gt>\n"
341 "#include E<lt>string.hE<gt>\n"
342 "\\&\n"
343 "int\n"
344 "main(void)\n"
345 "{\n"
346 " char *buf1;\n"
347 " size_t len, size;\n"
348 "\\&\n"
349 " size = strlen(\"Hello \") + strlen(\"world\") + strlen(\"!\") + 1;\n"
350 " buf1 = malloc(sizeof(*buf1) * size);\n"
351 " if (buf1 == NULL)\n"
352 " err(EXIT_FAILURE, \"malloc()\");\n"
353 "\\&\n"
354 " strcpy(buf1, \"Hello \");\n"
355 " strcat(buf1, \"world\");\n"
356 " strcat(buf1, \"!\");\n"
357 " len = strlen(buf1);\n"
358 "\\&\n"
359 " printf(\"[len = %zu]: \", len);\n"
360 " puts(buf1); // \"Hello world!\"\n"
361 " free(buf1);\n"
362 "\\&\n"
363 " exit(EXIT_SUCCESS);\n"
364 "}\n"
365 msgstr ""
366
367 #. SRC END
368 #. type: SH
369 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
370 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
371 #, no-wrap
372 msgid "SEE ALSO"
373 msgstr "СМОТРИТЕ ТАКЖЕ"
374
375 #. type: Plain text
376 #: archlinux debian-unstable opensuse-leap-16-1 opensuse-tumbleweed
377 #, fuzzy
378 #| msgid ""
379 #| "B<ceil>(3), B<floor>(3), B<lrint>(3), B<nearbyint>(3), B<rint>(3), "
380 #| "B<round>(3)"
381 msgid ""
382 "B<stpcpy>(3), B<strdup>(3), B<string>(3), B<wcscpy>(3), B<string_copying>(7)"
383 msgstr ""
384 "B<ceil>(3), B<floor>(3), B<lrint>(3), B<nearbyint>(3), B<rint>(3), "
385 "B<round>(3)"
386
387 #. type: TH
388 #: debian-trixie
389 #, no-wrap
390 msgid "2024-06-15"
391 msgstr "15 июня 2024 г."
392
393 #. type: TH
394 #: debian-trixie
395 #, no-wrap
396 msgid "Linux man-pages 6.9.1"
397 msgstr "Страницы руководства Linux 6.9.1"
398
399 #. type: Plain text
400 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
401 #, fuzzy
402 #| msgid "strcpy, strncpy - copy a string"
403 msgid "stpcpy, strcpy, strcat - copy or catenate a string"
404 msgstr "strcpy, strncpy - копирование строки"
405
406 #. type: Plain text
407 #: debian-trixie
408 msgid "Standard C library (I<libc>, I<-lc>)"
409 msgstr "Стандартная библиотека языка C (I<libc>, I<-lc>)"
410
411 #. type: Plain text
412 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
413 #, fuzzy, no-wrap
414 #| msgid ""
415 #| "B<char *strndup(const char *>I<s>B<, size_t >I<n>B<);>\n"
416 #| "B<char *strdupa(const char *>I<s>B<);>\n"
417 #| "B<char *strndupa(const char *>I<s>B<, size_t >I<n>B<);>\n"
418 msgid ""
419 "B<char *stpcpy(char *restrict >I<dst>B<, const char *restrict >I<src>B<);>\n"
420 "B<char *strcpy(char *restrict >I<dst>B<, const char *restrict >I<src>B<);>\n"
421 "B<char *strcat(char *restrict >I<dst>B<, const char *restrict >I<src>B<);>\n"
422 msgstr ""
423 "B<char *strndup(const char *>I<s>B<, size_t >I<n>B<);>\n"
424 "B<char *strdupa(const char *>I<s>B<);>\n"
425 "B<char *strndupa(const char *>I<s>B<, size_t >I<n>B<);>\n"
426
427 #. type: Plain text
428 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
429 msgid ""
430 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
431 msgstr ""
432 "Требования макроса тестирования свойств для glibc (см. "
433 "B<feature_test_macros>(7)):"
434
435 #. type: Plain text
436 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
437 msgid "B<stpcpy>():"
438 msgstr "B<stpcpy>():"
439
440 #. type: Plain text
441 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
442 #, no-wrap
443 msgid ""
444 " Since glibc 2.10:\n"
445 " _POSIX_C_SOURCE E<gt>= 200809L\n"
446 " Before glibc 2.10:\n"
447 " _GNU_SOURCE\n"
448 msgstr ""
449 " Начиная с glibc 2.10:\n"
450 " _POSIX_C_SOURCE E<gt>= 200809L\n"
451 " До glibc 2.10:\n"
452 " _BSD_SOURCE\n"
453
454 #. type: TP
455 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
456 #, no-wrap
457 msgid "B<stpcpy>()"
458 msgstr "B<stpcpy>()"
459
460 #. type: Plain text
461 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
462 msgid ""
463 "These functions copy the string pointed to by I<src>, into a string at the "
464 "buffer pointed to by I<dst>. The programmer is responsible for allocating a "
465 "destination buffer large enough, that is, I<strlen(src) + 1>. For the "
466 "difference between the two functions, see RETURN VALUE."
467 msgstr ""
468
469 #. type: Plain text
470 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
471 msgid "An implementation of these functions might be:"
472 msgstr "Реализация этих функций может быть:"
473
474 #. type: Plain text
475 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
476 #, no-wrap
477 msgid ""
478 "char *\n"
479 "stpcpy(char *restrict dst, const char *restrict src)\n"
480 "{\n"
481 " char *p;\n"
482 "\\&\n"
483 " p = mempcpy(dst, src, strlen(src));\n"
484 " *p = \\[aq]\\[rs]0\\[aq];\n"
485 "\\&\n"
486 " return p;\n"
487 "}\n"
488 "\\&\n"
489 "char *\n"
490 "strcpy(char *restrict dst, const char *restrict src)\n"
491 "{\n"
492 " stpcpy(dst, src);\n"
493 " return dst;\n"
494 "}\n"
495 "\\&\n"
496 "char *\n"
497 "strcat(char *restrict dst, const char *restrict src)\n"
498 "{\n"
499 " stpcpy(dst + strlen(dst), src);\n"
500 " return dst;\n"
501 "}\n"
502 msgstr ""
503
504 #. type: Plain text
505 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
506 msgid ""
507 "This function returns a pointer to the terminating null byte of the copied "
508 "string."
509 msgstr ""
510
511 #. type: tbl table
512 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
513 #, fuzzy, no-wrap
514 #| msgid ""
515 #| "B<strcpy>(),\n"
516 #| "B<strncpy>()"
517 msgid ""
518 "B<stpcpy>(),\n"
519 "B<strcpy>(),\n"
520 "B<strcat>()"
521 msgstr ""
522 "B<strcpy>(),\n"
523 "B<strncpy>()"
524
525 #. type: Plain text
526 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
527 msgid "POSIX.1-2008."
528 msgstr "POSIX.1-2008."
529
530 #. type: Plain text
531 #: debian-trixie fedora-44 fedora-rawhide
532 msgid ""
533 "B<strcat>() can be very inefficient. Read about E<.UR https://"
534 "www.joelonsoftware.com/\\:2001/12/11/\\:back-to-basics/> Shlemiel the "
535 "painter E<.UE .>"
536 msgstr ""
537
538 #. type: Plain text
539 #: debian-trixie
540 #, no-wrap
541 msgid ""
542 "#include E<lt>err.hE<gt>\n"
543 "#include E<lt>stdio.hE<gt>\n"
544 "#include E<lt>stdlib.hE<gt>\n"
545 "#include E<lt>string.hE<gt>\n"
546 "\\&\n"
547 "int\n"
548 "main(void)\n"
549 "{\n"
550 " char *p;\n"
551 " char *buf1;\n"
552 " char *buf2;\n"
553 " size_t len, maxsize;\n"
554 "\\&\n"
555 " maxsize = strlen(\"Hello \") + strlen(\"world\") + strlen(\"!\") + 1;\n"
556 " buf1 = malloc(sizeof(*buf1) * maxsize);\n"
557 " if (buf1 == NULL)\n"
558 " err(EXIT_FAILURE, \"malloc()\");\n"
559 " buf2 = malloc(sizeof(*buf2) * maxsize);\n"
560 " if (buf2 == NULL)\n"
561 " err(EXIT_FAILURE, \"malloc()\");\n"
562 "\\&\n"
563 " p = buf1;\n"
564 " p = stpcpy(p, \"Hello \");\n"
565 " p = stpcpy(p, \"world\");\n"
566 " p = stpcpy(p, \"!\");\n"
567 " len = p - buf1;\n"
568 "\\&\n"
569 " printf(\"[len = %zu]: \", len);\n"
570 " puts(buf1); // \"Hello world!\"\n"
571 " free(buf1);\n"
572 "\\&\n"
573 " strcpy(buf2, \"Hello \");\n"
574 " strcat(buf2, \"world\");\n"
575 " strcat(buf2, \"!\");\n"
576 " len = strlen(buf2);\n"
577 "\\&\n"
578 " printf(\"[len = %zu]: \", len);\n"
579 " puts(buf2); // \"Hello world!\"\n"
580 " free(buf2);\n"
581 "\\&\n"
582 " exit(EXIT_SUCCESS);\n"
583 "}\n"
584 msgstr ""
585
586 #. type: Plain text
587 #: debian-trixie fedora-44 fedora-rawhide mageia-cauldron
588 msgid "B<strdup>(3), B<string>(3), B<wcscpy>(3), B<string_copying>(7)"
589 msgstr ""
590
591 #. type: TH
592 #: fedora-44 fedora-rawhide
593 #, no-wrap
594 msgid "2024-11-17"
595 msgstr "17 ноября 2024 г."
596
597 #. type: TH
598 #: fedora-44 fedora-rawhide
599 #, no-wrap
600 msgid "Linux man-pages 6.13"
601 msgstr "Страницы руководства Linux 6.13"
602
603 #. type: Plain text
604 #: fedora-44 fedora-rawhide mageia-cauldron
605 #, no-wrap
606 msgid ""
607 "#include E<lt>err.hE<gt>\n"
608 "#include E<lt>stdio.hE<gt>\n"
609 "#include E<lt>stdlib.hE<gt>\n"
610 "#include E<lt>string.hE<gt>\n"
611 "\\&\n"
612 "int\n"
613 "main(void)\n"
614 "{\n"
615 " char *p;\n"
616 " char *buf1;\n"
617 " char *buf2;\n"
618 " size_t len, size;\n"
619 "\\&\n"
620 " size = strlen(\"Hello \") + strlen(\"world\") + strlen(\"!\") + 1;\n"
621 " buf1 = malloc(sizeof(*buf1) * size);\n"
622 " if (buf1 == NULL)\n"
623 " err(EXIT_FAILURE, \"malloc()\");\n"
624 " buf2 = malloc(sizeof(*buf2) * size);\n"
625 " if (buf2 == NULL)\n"
626 " err(EXIT_FAILURE, \"malloc()\");\n"
627 "\\&\n"
628 " p = buf1;\n"
629 " p = stpcpy(p, \"Hello \");\n"
630 " p = stpcpy(p, \"world\");\n"
631 " p = stpcpy(p, \"!\");\n"
632 " len = p - buf1;\n"
633 "\\&\n"
634 " printf(\"[len = %zu]: \", len);\n"
635 " puts(buf1); // \"Hello world!\"\n"
636 " free(buf1);\n"
637 "\\&\n"
638 " strcpy(buf2, \"Hello \");\n"
639 " strcat(buf2, \"world\");\n"
640 " strcat(buf2, \"!\");\n"
641 " len = strlen(buf2);\n"
642 "\\&\n"
643 " printf(\"[len = %zu]: \", len);\n"
644 " puts(buf2); // \"Hello world!\"\n"
645 " free(buf2);\n"
646 "\\&\n"
647 " exit(EXIT_SUCCESS);\n"
648 "}\n"
649 msgstr ""
650
651 #. type: TH
652 #: mageia-cauldron
653 #, no-wrap
654 msgid "2025-12-25"
655 msgstr "25 декабря 2025 г."
656
657 #. type: TH
658 #: mageia-cauldron
659 #, no-wrap
660 msgid "Linux man-pages 6.17"
661 msgstr "Страницы руководства Linux 6.17"
662
663 #. type: TH
664 #: opensuse-leap-16-1 opensuse-tumbleweed
665 #, no-wrap
666 msgid "Linux man-pages (unreleased)"
667 msgstr "Страницы руководства Linux (не выпущены)"