aboutsummaryrefslogtreecommitdiff
path: root/src/libmach/sym.c
diff options
context:
space:
mode:
authorPetter Rodhelind <petter.rodhelind@gmail.com>2020-01-14 11:41:08 +0100
committerPetter Rodhelind <petter.rodhelind@gmail.com>2020-01-14 11:41:08 +0100
commit02d7aa8915f9c3a3288dab01f321eb94ba219e3b (patch)
treef053238978479e408a2b83571443e132f30586ab /src/libmach/sym.c
parentc0c9d8f883dfd3a7f5a74499d91bb95884b15873 (diff)
parent3d1382b98a502d0c34d5ba2c462396acc515016e (diff)
downloadplan9port-02d7aa8915f9c3a3288dab01f321eb94ba219e3b.tar.gz
plan9port-02d7aa8915f9c3a3288dab01f321eb94ba219e3b.tar.bz2
plan9port-02d7aa8915f9c3a3288dab01f321eb94ba219e3b.zip
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'src/libmach/sym.c')
-rw-r--r--src/libmach/sym.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/libmach/sym.c b/src/libmach/sym.c
index 6369cdd1..b165e125 100644
--- a/src/libmach/sym.c
+++ b/src/libmach/sym.c
@@ -296,7 +296,7 @@ ffindsym(Fhdr *fhdr, Loc loc, uint class)
* We want to find the largest index i such that
* a[i] <= loc. This cannot be done with a simple
* binary search. Instead we binary search to find
- * where the location should be.
+ * where the location should be.
*/
lo = 0;
hi = n;
@@ -529,7 +529,7 @@ symopen(Fhdr *hdr)
hdr->byname[i] = &hdr->sym[i];
qsort(hdr->byname, hdr->nsym, sizeof(hdr->byname[0]), bynamecmp);
}
-
+
hdr->byxname = malloc(hdr->nsym*sizeof(hdr->byxname[0]));
if(hdr->byxname == nil){
fprint(2, "could not allocate table to sort by xname\n");
@@ -581,4 +581,3 @@ _addsym(Fhdr *fp, Symbol *sym)
*s = *sym;
return s;
}
-