Skip to content

Commit

Permalink
Fix memory leak
Browse files Browse the repository at this point in the history
  • Loading branch information
Teka101 authored and Teka101 committed Jan 15, 2018
1 parent 5c89054 commit a7715d8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions SftpServer/SftpExt.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ void DoExtDiskSpace(tBuffer *bIn, tBuffer *bOut, u_int32_t id)
BufferPutInt64(b, (u_int64_t) stfs.f_bavail * (u_int64_t) stfs.f_bsize);
BufferPutInt32(b, stfs.f_bsize);
BufferPutPacket(bOut, b);
BufferDelete(b);
}
else
SendStatus(bOut, id, errnoToPortable(errno));
Expand Down Expand Up @@ -103,6 +104,7 @@ static void DoExtDiskSpaceOpenSSH_Path(tBuffer *bOut, u_int32_t id, const char *
BufferPutInt64(b, stfs.f_flag); /* bit mask of f_flag values */
BufferPutInt64(b, stfs.f_namemax); /* maximum filename length */
BufferPutPacket(bOut, b);
BufferDelete(b);
}
else
{
Expand Down

0 comments on commit a7715d8

Please sign in to comment.