Fossil

Check-in [ffe2a84cec]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Remove legacy code that attempted to use -P instead of -p on "plink" for the port number of SSH.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: ffe2a84ceca6a177f072d5a8ebc0f833df88a85b4428ca4b66cd2ff2df312064
User & Date: drh 2021-06-30 13:07:41.775
Context
2021-06-30
13:52
Enhance the blob_append_escaped_args() routine with a new parameter to indicate if the argument is a filename. Only prepend "./" to filename arguments that begin with "-". The "%$" printf conversion assumes a filename, but the "%!$" conversion does not. check-in: 4f83d06275 user: drh tags: trunk
13:07
Remove legacy code that attempted to use -P instead of -p on "plink" for the port number of SSH. check-in: ffe2a84cec user: drh tags: trunk
2021-06-29
05:05
Fixed a && which was supposed to be a & in the new patch code. Caught by gcc. check-in: 1fd6961005 user: stephan tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/http_transport.c.
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
  */
  Blob zCmd;         /* The SSH command */
  char *zHost;       /* The host name to contact */

  socket_ssh_resolve_addr(pUrlData);
  transport_ssh_command(&zCmd);
  if( pUrlData->port!=pUrlData->dfltPort && pUrlData->port ){
#ifdef _WIN32
    blob_appendf(&zCmd, " -P %d", pUrlData->port);
#else
    blob_appendf(&zCmd, " -p %d", pUrlData->port);
#endif
  }
  if( pUrlData->user && pUrlData->user[0] ){
    zHost = mprintf("%s@%s", pUrlData->user, pUrlData->name);
    blob_append_escaped_arg(&zCmd, zHost);
    fossil_free(zHost);
  }else{
    blob_append_escaped_arg(&zCmd, pUrlData->name);







<
<
<

<







118
119
120
121
122
123
124



125

126
127
128
129
130
131
132
  */
  Blob zCmd;         /* The SSH command */
  char *zHost;       /* The host name to contact */

  socket_ssh_resolve_addr(pUrlData);
  transport_ssh_command(&zCmd);
  if( pUrlData->port!=pUrlData->dfltPort && pUrlData->port ){



    blob_appendf(&zCmd, " -p %d", pUrlData->port);

  }
  if( pUrlData->user && pUrlData->user[0] ){
    zHost = mprintf("%s@%s", pUrlData->user, pUrlData->name);
    blob_append_escaped_arg(&zCmd, zHost);
    fossil_free(zHost);
  }else{
    blob_append_escaped_arg(&zCmd, pUrlData->name);