Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
862d5626
Commit
862d5626
authored
Aug 07, 2006
by
msvensson@neptunus.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add some more code to analyze why the fgets fails.
parent
419e4dd4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
tests/mysql_client_test.c
tests/mysql_client_test.c
+12
-3
No files found.
tests/mysql_client_test.c
View file @
862d5626
...
...
@@ -14951,9 +14951,18 @@ static void test_bug17667()
do
{
memset
(
line_buffer
,
'/'
,
MAX_TEST_QUERY_LENGTH
*
2
);
DIE_UNLESS
(
fgets
(
line_buffer
,
MAX_TEST_QUERY_LENGTH
*
2
,
log_file
)
!=
NULL
);
/* If we reach EOF before finishing the statement list, then we failed. */
if
(
fgets
(
line_buffer
,
MAX_TEST_QUERY_LENGTH
*
2
,
log_file
)
==
NULL
)
{
/* If fgets returned NULL, it indicates either error or EOF */
if
(
feof
(
log_file
))
DIE
(
"Found EOF before all statements where found"
);
else
{
fprintf
(
stderr
,
"Got error %d while reading from file
\n
"
,
ferror
(
log_file
));
DIE
(
"Read error"
);
}
}
}
while
(
my_memmem
(
line_buffer
,
MAX_TEST_QUERY_LENGTH
*
2
,
statement_cursor
->
buffer
,
statement_cursor
->
length
)
==
NULL
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment