mirror of
https://github.com/gryf/snipmate.vim.git
synced 2026-11-24 00:16:55 +01:00
fixed typo in C++ snippets
This commit is contained in:
1 parent
d2e3387761
commit
ff1dc54cda
1 file changed
+1
-2
@@ -3,8 +3,7 @@ snippet readfile
|
|||||||
std::vector<char> v;
|
std::vector<char> v;
|
||||||
if (FILE *${2:fp} = fopen(${1:"filename"}, "r")) {
|
if (FILE *${2:fp} = fopen(${1:"filename"}, "r")) {
|
||||||
char buf[1024];
|
char buf[1024];
|
||||||
while (size_t len =
|
while (size_t len = fread(buf, 1, sizeof(buf), $2))
|
||||||
fread(buf, 1, sizeof(buf), $2))
|
|
||||||
v.insert(v.end(), buf, buf + len);
|
v.insert(v.end(), buf, buf + len);
|
||||||
fclose($2);
|
fclose($2);
|
||||||
}${3}
|
}${3}
|
||||||
|
|||||||
Reference in new issue
Block a user