Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
cta
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Harbor Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dCache
cta
Commits
d95739d5
Commit
d95739d5
authored
22 years ago
by
Jean-Damien Durand
Committed by
Steven Murray
7 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Accept nbytes == 0 in netread/netwrite/netread_timeout/netwrite_timeout
parent
4e7177cb
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
mediachanger/castorrmc/common/socket.c
+2
-2
2 additions, 2 deletions
mediachanger/castorrmc/common/socket.c
mediachanger/castorrmc/common/socket_timeout.c
+5
-5
5 additions, 5 deletions
mediachanger/castorrmc/common/socket_timeout.c
with
7 additions
and
7 deletions
mediachanger/castorrmc/common/socket.c
+
2
−
2
View file @
d95739d5
...
...
@@ -171,7 +171,7 @@ int nbytes;
{
register
int
n
,
nb
;
if
(
nbytes
<
=
0
)
{
if
(
nbytes
<
0
)
{
serrno
=
EINVAL
;
return
(
-
1
);
}
...
...
@@ -243,7 +243,7 @@ int nbytes;
{
register
int
n
,
nb
;
if
(
nbytes
<
=
0
)
{
if
(
nbytes
<
0
)
{
serrno
=
EINVAL
;
return
(
-
1
);
}
...
...
This diff is collapsed.
Click to expand it.
mediachanger/castorrmc/common/socket_timeout.c
+
5
−
5
View file @
d95739d5
...
...
@@ -4,7 +4,7 @@
*/
#ifndef lint
static
char
sccsid
[]
=
"@(#)$RCSfile: socket_timeout.c,v $ $Revision: 1.1
7
$ $Date: 200
1/10/23 06:24:45
$ CERN IT-PDP/DM Jean-Damien Durand"
;
static
char
sccsid
[]
=
"@(#)$RCSfile: socket_timeout.c,v $ $Revision: 1.1
8
$ $Date: 200
2/09/04 07:35:10
$ CERN IT-PDP/DM Jean-Damien Durand"
;
#endif
/* not lint */
#include
<stdlib.h>
...
...
@@ -163,8 +163,8 @@ ssize_t DLL_DECL netread_timeout(fd, vptr, n, timeout)
time_t
time_start
;
int
time_elapsed
;
/* If n <
=
0
(on some systems size_t can be lower than zero)
it is an app. error */
if
(
n
<
=
0
)
{
/* If n < 0 it is an app. error */
if
(
n
<
0
)
{
serrno
=
EINVAL
;
return
(
-
1
);
}
...
...
@@ -265,8 +265,8 @@ ssize_t DLL_DECL netwrite_timeout(fd, vptr, n, timeout)
time_t
time_start
;
int
time_elapsed
;
/* If n <
=
0
(on some systems size_t can be lower than zero)
it is an app. error */
if
(
n
<
=
0
)
{
/* If n < 0 it is an app. error */
if
(
n
<
0
)
{
serrno
=
EINVAL
;
return
(
-
1
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment