Changeset 561 for trunk/src/sh_xfer_server.c
- Timestamp:
- Jun 29, 2021, 10:19:30 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_xfer_server.c
r544 r561 1230 1230 int bytes; 1231 1231 SL_TICKET sfd = -1; 1232 #ifdef SH_ENCRYPT1233 int blkfac;1234 int rem;1235 int send_bytes;1236 #endif1237 1232 1238 1233 if (conn == NULL || conn->FileName == NULL) … … 1281 1276 if (bytes >= 0) 1282 1277 { 1278 send_buf = hash_me(conn->K, read_buf, bytes); 1283 1279 #ifdef SH_ENCRYPT 1284 /* need to send N * B_SIZ bytes 1285 */ 1286 blkfac = bytes / B_SIZ; 1287 rem = bytes - (blkfac * B_SIZ); 1288 if (rem != 0) 1289 { 1290 memset(&read_buf[bytes], '\n', (B_SIZ-rem)); 1291 ++blkfac; 1292 send_bytes = blkfac * B_SIZ; 1293 } 1294 else 1295 send_bytes = bytes; 1296 1297 send_buf = hash_me(conn->K, read_buf, send_bytes); 1298 1299 sh_xfer_send_crypt (conn, send_buf, send_bytes+KEY_LEN, _("FILE"), 1280 sh_xfer_send_crypt (conn, send_buf, bytes+KEY_LEN, _("FILE"), 1300 1281 SH_PROTO_BIG|conn->client_entry->encf_flag); 1301 1282 #else 1302 send_buf = hash_me(conn->K, read_buf, bytes);1303 1283 sh_xfer_send_crypt (conn, send_buf, bytes+KEY_LEN, _("FILE"), 1304 1284 SH_PROTO_BIG);
Note:
See TracChangeset
for help on using the changeset viewer.