@@ -2357,9 +2357,9 @@ int wolfSSH_SFTP_RecvOpen(WOLFSSH* ssh, int reqId, byte* data, word32 maxSz)
23572357
23582358 if (ret == WS_SUCCESS ) {
23592359 /* Generate unique file handle ID and add to tracking list */
2360- id [0 ] = ssh -> fileIdCount [0 ];
2361- id [1 ] = ssh -> fileIdCount [1 ];
2362- AddAssign64 (ssh -> fileIdCount , 1 );
2360+ id [0 ] = ssh -> handleIdCount [0 ];
2361+ id [1 ] = ssh -> handleIdCount [1 ];
2362+ AddAssign64 (ssh -> handleIdCount , 1 );
23632363
23642364 if ((ret = SFTP_AddFileHandle (ssh , fd , dir , id )) != WS_SUCCESS ) {
23652365 WLOG (WS_LOG_SFTP , "Unable to store handle" );
@@ -2541,9 +2541,9 @@ int wolfSSH_SFTP_RecvOpen(WOLFSSH* ssh, int reqId, byte* data, word32 maxSz)
25412541
25422542 if (ret == WS_SUCCESS ) {
25432543 /* Generate unique file handle ID and add to tracking list */
2544- id [0 ] = ssh -> fileIdCount [0 ];
2545- id [1 ] = ssh -> fileIdCount [1 ];
2546- AddAssign64 (ssh -> fileIdCount , 1 );
2544+ id [0 ] = ssh -> handleIdCount [0 ];
2545+ id [1 ] = ssh -> handleIdCount [1 ];
2546+ AddAssign64 (ssh -> handleIdCount , 1 );
25472547
25482548 if (SFTP_AddFileHandle (ssh , fileHandle , dir , id ) != WS_SUCCESS ) {
25492549 WLOG (WS_LOG_SFTP , "Unable to store handle" );
@@ -2713,11 +2713,11 @@ int wolfSSH_SFTP_RecvOpenDir(WOLFSSH* ssh, int reqId, byte* data, word32 maxSz)
27132713#else
27142714 cur -> dir = ctx ;
27152715#endif
2716- cur -> id [0 ] = id [0 ] = ssh -> dirIdCount [0 ];
2717- cur -> id [1 ] = id [1 ] = ssh -> dirIdCount [1 ];
2716+ cur -> id [0 ] = id [0 ] = ssh -> handleIdCount [0 ];
2717+ cur -> id [1 ] = id [1 ] = ssh -> handleIdCount [1 ];
27182718 c32toa (id [0 ], idFlat );
27192719 c32toa (id [1 ], idFlat + UINT32_SZ );
2720- AddAssign64 (ssh -> dirIdCount , 1 );
2720+ AddAssign64 (ssh -> handleIdCount , 1 );
27212721 cur -> isEof = 0 ;
27222722 cur -> next = ssh -> dirList ;
27232723 ssh -> dirList = cur ;
@@ -2872,11 +2872,11 @@ int wolfSSH_SFTP_RecvOpenDir(WOLFSSH* ssh, int reqId, byte* data, word32 maxSz)
28722872 return WS_MEMORY_E ;
28732873 }
28742874 cur -> dir = INVALID_HANDLE_VALUE ;
2875- cur -> id [0 ] = id [0 ] = ssh -> dirIdCount [0 ];
2876- cur -> id [1 ] = id [1 ] = ssh -> dirIdCount [1 ];
2875+ cur -> id [0 ] = id [0 ] = ssh -> handleIdCount [0 ];
2876+ cur -> id [1 ] = id [1 ] = ssh -> handleIdCount [1 ];
28772877 c32toa (id [0 ], idFlat );
28782878 c32toa (id [1 ], idFlat + UINT32_SZ );
2879- AddAssign64 (ssh -> dirIdCount , 1 );
2879+ AddAssign64 (ssh -> handleIdCount , 1 );
28802880 cur -> isEof = 0 ;
28812881 cur -> dirName = dirName ; /* take over ownership of buffer */
28822882 cur -> next = ssh -> dirList ;
0 commit comments