Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Update auto.def and relevant source files to account for the definition of getpass() in Termux' unistd.h. |
|---|---|
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
f2aa77cc3fd3bd42ceb2f7fdfd461f6a |
| User & Date: | danield 2021-01-06 15:58:50.949 |
Context
|
2021-01-06
| ||
| 16:28 | Set the gitmirror_mainbranch value earlier to avoid creating a default branch with the wrong name in new exports. check-in: dbcf66b57f user: drh tags: trunk | |
| 15:58 | Update auto.def and relevant source files to account for the definition of getpass() in Termux' unistd.h. check-in: f2aa77cc3f user: danield tags: trunk | |
| 15:38 | Fix multiple problems with check-in [9360b66a67086d64] that can lead to crashes in Fossil itself, and in git-fast-import, when attempting to mirror the Fossil self-hosting repository to Git. check-in: b001a1c3de user: drh tags: trunk | |
Changes
Changes to auto.def.
| ︙ | ︙ | |||
568 569 570 571 572 573 574 575 576 577 578 579 580 581 |
# Other nonstandard function checks
cc-check-functions utime
cc-check-functions usleep
cc-check-functions strchrnul
cc-check-functions pledge
cc-check-functions backtrace
# Check for getloadavg(), and if it doesn't exist, define FOSSIL_OMIT_LOAD_AVERAGE
if {![cc-check-functions getloadavg]} {
define FOSSIL_OMIT_LOAD_AVERAGE 1
msg-result "Load average support unavailable"
}
| > > > > > > > > | 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 |
# Other nonstandard function checks
cc-check-functions utime
cc-check-functions usleep
cc-check-functions strchrnul
cc-check-functions pledge
cc-check-functions backtrace
# Termux on Android adds "getpass(char *)" to unistd.h, so check this so we
# guard against including it again; use cctest as cc-check-functions and
# cctest_function check for "getpass()" with no args and fail
if {[cctest -link 1 -includes {unistd.h} -code "getpass(0);"]} {
define FOSSIL_HAVE_GETPASS 1
msg-result "Found getpass() with unistd.h"
}
# Check for getloadavg(), and if it doesn't exist, define FOSSIL_OMIT_LOAD_AVERAGE
if {![cc-check-functions getloadavg]} {
define FOSSIL_OMIT_LOAD_AVERAGE 1
msg-result "Load average support unavailable"
}
|
| ︙ | ︙ |
Changes to src/main.c.
| ︙ | ︙ | |||
343 344 345 346 347 348 349 | if( once++ ) return; /* Ensure that this routine only runs once */ #if USE_SEE /* ** Zero, unlock, and free the saved database encryption key now. */ db_unsave_encryption_key(); #endif | | | 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 |
if( once++ ) return; /* Ensure that this routine only runs once */
#if USE_SEE
/*
** Zero, unlock, and free the saved database encryption key now.
*/
db_unsave_encryption_key();
#endif
#if defined(_WIN32) || defined(__BIONIC__) && !defined(FOSSIL_HAVE_GETPASS)
/*
** Free the secure getpass() buffer now.
*/
freepass();
#endif
#if defined(_WIN32) && !defined(_WIN64) && defined(FOSSIL_ENABLE_TCL) && \
defined(USE_TCL_STUBS)
|
| ︙ | ︙ |
Changes to src/user.c.
| ︙ | ︙ | |||
36 37 38 39 40 41 42 |
break;
}
if( z[i]>0 && z[i]<' ' ) z[i] = ' ';
}
blob_append(pBlob, z, -1);
}
| | | 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
break;
}
if( z[i]>0 && z[i]<' ' ) z[i] = ' ';
}
blob_append(pBlob, z, -1);
}
#if defined(_WIN32) || defined(__BIONIC__) && !defined(FOSSIL_HAVE_GETPASS)
#ifdef _WIN32
#include <conio.h>
#endif
/*
** getpass() for Windows and Android.
*/
|
| ︙ | ︙ |