| Summary: | type fixes for progressmeter | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | Portable OpenSSH | Reporter: | Darren Tucker <dtucker> | ||||||
| Component: | sftp | Assignee: | OpenSSH Bugzilla mailing list <openssh-bugs> | ||||||
| Status: | CLOSED FIXED | ||||||||
| Severity: | normal | CC: | djm | ||||||
| Priority: | P2 | ||||||||
| Version: | -current | ||||||||
| Hardware: | All | ||||||||
| OS: | All | ||||||||
| Bug Depends on: | |||||||||
| Bug Blocks: | 1353 | ||||||||
| Attachments: |
|
||||||||
|
Description
Darren Tucker
2004-04-15 14:03:16 AEST
Created attachment 604 [details]
use u_int64_t for progressmeter
Is this still relevant? What compile warnings do you see? The error is: sftp-client.c:1051: cannot cast 'unsigned long long *' to 'int *' The line in question is: start_progress_meter(local_path, sb.st_size, &offset); "offset" is u_int64_t, the 3rd arg of start_progress_meter is off_t. Since off_t is usually signed, it's also a potential signed/unsigned issue. Created attachment 1287 [details]
make sftp use off_t
Perhaps it would be better for sftp to use an off_t here? I don't think the OS would support files with OFF_T_MAX < size <= UINT64_MAX anyway
(In reply to comment #4) > Perhaps it would be better for sftp to use an off_t here? I don't think > the OS would support files with OFF_T_MAX < size <= UINT64_MAX anyway This seems reasonable to me. The progressmeter code doesn't seem like it would care much if it wrapped anyway, other than producing bogus stats. Fix shipped in 4.9/4.9p1 release. |