/dev/stdout
4.05K subscribers
19.6K photos
2.69K videos
78 files
3.26K links
cat /dev/random
Download Telegram
Я паяльник чуть не упустил на ногу
😭10🥰2🍓1
This media is not supported in your browser
VIEW IN TELEGRAM
🍓2
1
12🤣7😭3🍓11
В чем блять USB C хорош кроме того что его пропихивают куда только можно и нельзя?
🥴4👍3
Суки
😭22🍓11
15🍓1
Кошкечка Альцгеймер
🍓3
10🍓3
🍓4💋4
I love how android just "hey, this app energy inefficient, take this restrictions" fighting developers and their bad code so they can "install there 10 apps, give every permission, set them in background, disable energy saving"
🥰7👍1💯1
This media is not supported in your browser
VIEW IN TELEGRAM
🤯4321🤩1🍓1
/dev/stdout
Sticker
This media is not supported in your browser
VIEW IN TELEGRAM
🍓6💅2
/dev/stdout
GIF
а можно постить другого кота каждого 19 числа
🤨6
/* cat -- concatenate files and print on the standard output.
Copyright (C) 1988-2026 Free Software Foundation, Inc.

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>. */

/* Differences from the Unix cat:
* Always unbuffered, -u is ignored.
* Usually much faster than other versions of cat, the difference
is especially apparent when using the -v option.

By tege@sics.se, Torbjörn Granlund, advised by rms, Richard Stallman. */

#include <config.h>

#include <stdio.h>
#include <getopt.h>
#include <sys/types.h>

#if HAVE_STROPTS_H
# include <stropts.h>
#endif
#include <sys/ioctl.h>

#include "system.h"
#include "alignalloc.h"
#include "ioblksize.h"
#include "fadvise.h"
#include "full-write.h"
#include "xbinary-io.h"

/* The official name of this program (e.g., no 'g' prefix). */
#define PROGRAM_NAME "cat"

#define AUTHORS \
proper_name_lite ("Torbjorn Granlund", "Torbj\303\266rn Granlund"), \
proper_name ("Richard M. Stallman")

/* Name of input file. May be "-". */
static char const *infile;

/* Descriptor on which input file is open. */
static int input_desc;

/* Buffer for line numbers.
An 11 digit counter may overflow within an hour on a P2/466,
an 18 digit counter needs about 1000y */
#define LINE_COUNTER_BUF_LEN 20
static char line_buf[LINE_COUNTER_BUF_LEN] =
{
' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',
' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '0',
'\t', '\0'
};

/* Position in 'line_buf' where printing starts. This will not change
unless the number of lines is larger than 999999. */
static char *line_num_print = line_buf + LINE_COUNTER_BUF_LEN - 8;

/* Position of the first digit in 'line_buf'. */
static char *line_num_start = line_buf + LINE_COUNTER_BUF_LEN - 3;

/* Position of the last digit in 'line_buf'. */
static char *line_num_end = line_buf + LINE_COUNTER_BUF_LEN - 3;

/* Preserves the 'cat' function's local 'newlines' between invocations. */
static int newlines2 = 0;

/* Whether there is a pending CR to process. */
static bool pending_cr = false;

void
usage (int status)
{
if (status != EXIT_SUCCESS)
emit_try_help ();
else
{
printf (_("\
Usage: %s [OPTION]... [FILE]...\n\
"),
program_name);
fputs (_("\
Concatenate FILE(s) to standard output.\n\
"), stdout);

emit_stdin_note ();

fputs (_("\
\n\
-A, --show-all equivalent to -vET\n\
-b, --number-nonblank number nonempty output lines, overrides -n\n\
-e equivalent to -vE\n\
-E, --show-ends display $ or ^M$ at end of each line\n\
-n, --number number all output lines\n\
-s, --squeeze-blank suppress repeated empty output lines\n\
"), stdout);
fputs (_("\
-t equivalent to -vT\n\
-T, --show-tabs display TAB characters as ^I\n\
-u (ignored)\n\
-v, --show-nonprinting use ^ and M- notation, except for LFD and TAB\n\
"), stdout);
fputs (HELP_OPTION_DESCRIPTION, stdout);
fputs (VERSION_OPTION_DESCRIPTION, stdout);
printf (_("\
\n\
Examples:\n\
%s f - g Output f's contents, then standard input, then g's contents.\n\
%s Copy standard input to standard output.\n\
"),
program_name, program_name);
emit_ancillary_info (PROGRAM_NAME);
}
exit (status);
}

/* Compute the next line number. */
🔥5