Commit 3d7e92b
committed
luzer: refactoring search_module_path()
The luzer module relies on other shared libraries: library with
custom mutator and sanitizer libraries built with libFuzzer.
These libraries are located in the directory with luzer_impl.so
and on module loading we search a path to this shared library
to found other shared libraries. It is done by the function
`search_module_path()` - it iterates through the directories
specified in the environment variable LUA_CPATH and tries to find
the directory with luzer_impl.so.
However, there's a simpler way to find a directory path with
luzer_impl.so - using the `dladdr(3)` function. The patch
refactors the function `search_module_path()` to make its
implementation easier for support.
Related to #671 parent 28b23b2 commit 3d7e92b
1 file changed
+16
-30
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | | - | |
145 | 144 | | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
164 | 155 | | |
165 | | - | |
| 156 | + | |
| 157 | + | |
166 | 158 | | |
167 | 159 | | |
168 | 160 | | |
| |||
183 | 175 | | |
184 | 176 | | |
185 | 177 | | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
190 | 182 | | |
191 | 183 | | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | 184 | | |
197 | 185 | | |
198 | 186 | | |
| |||
208 | 196 | | |
209 | 197 | | |
210 | 198 | | |
211 | | - | |
212 | | - | |
213 | 199 | | |
214 | 200 | | |
215 | 201 | | |
| |||
0 commit comments