From 1aec66e8a18e99df3dcaae2730099daacf0030b3 Mon Sep 17 00:00:00 2001 From: Kurtis Rader Date: Tue, 1 Aug 2017 16:54:32 -0700 Subject: [PATCH] document special value zero for FISH_READ_BYTE_LIMIT --- doc_src/index.hdr.in | 2 +- doc_src/read.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc_src/index.hdr.in b/doc_src/index.hdr.in index 15abeb535..8994a0cb4 100644 --- a/doc_src/index.hdr.in +++ b/doc_src/index.hdr.in @@ -474,7 +474,7 @@ The exit status of the last run command substitution is available in the index range expansion for details. -Fish has a default limit of 10 MiB on the amount of data a command substitution can output. If the limit is exceeded the entire command, not just the substitution, is failed and `$status` is set to 122. You can modify the limit by setting the `FISH_READ_BYTE_LIMIT` variable at any time including in the environment before fish starts running. This is a safety mechanism to keep the shell from consuming an too much memory if a command outputs an unreasonable amount of data. Note that this limit also affects how much data the `read` command will process. +Fish has a default limit of 10 MiB on the amount of data a command substitution can output. If the limit is exceeded the entire command, not just the substitution, is failed and `$status` is set to 122. You can modify the limit by setting the `FISH_READ_BYTE_LIMIT` variable at any time including in the environment before fish starts running. If you set it to zero then no limit is imposed. This is a safety mechanism to keep the shell from consuming an too much memory if a command outputs an unreasonable amount of data. Note that this limit also affects how much data the `read` command will process. Examples: diff --git a/doc_src/read.txt b/doc_src/read.txt index ffc02d21a..fa176c004 100644 --- a/doc_src/read.txt +++ b/doc_src/read.txt @@ -49,7 +49,7 @@ See the documentation for `set` for more details on the scoping rules for variab When read reaches the end-of-file (EOF) instead of the separator, it sets `$status` to 1. If not, it sets it to 0. -Fish has a default limit of 10 MiB on the number of characters each `read` will consume. If you attempt to read more than that `$status` is set to 122 and the variable will be empty. You can modify that limit by setting the `FISH_READ_BYTE_LIMIT` variable at any time including in the environment before fish starts running. This is a safety mechanism to keep the shell from consuming an unreasonable amount of memory if the input is malformed. Note that this limit also affects how much data a command substitution is allowed to output. +Fish has a default limit of 10 MiB on the number of characters each `read` will consume. If you attempt to read more than that `$status` is set to 122 and the variable will be empty. You can modify that limit by setting the `FISH_READ_BYTE_LIMIT` variable at any time including in the environment before fish starts running. If you set it to zero then no limit is imposed. This is a safety mechanism to keep the shell from consuming an unreasonable amount of memory if the input is malformed. Note that this limit also affects how much data a command substitution is allowed to output. \subsection read-history Using another read history file