Author: tridge Date: 2005-08-17 01:40:14 +0000 (Wed, 17 Aug 2005) New Revision: 9341
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=9341 Log: updated the winreg test program to take advantage of the new EnumValue functionality. It now completely enumerates a winreg tree. This would make a good basis for a js version of regshell if someone felt like taking that on. Modified: branches/SAMBA_4_0/testprogs/ejs/winreg.js Changeset: Modified: branches/SAMBA_4_0/testprogs/ejs/winreg.js =================================================================== --- branches/SAMBA_4_0/testprogs/ejs/winreg.js 2005-08-17 01:30:47 UTC (rev 9340) +++ branches/SAMBA_4_0/testprogs/ejs/winreg.js 2005-08-17 01:40:14 UTC (rev 9341) @@ -34,13 +34,22 @@ return -1; } -function list_path(path) { - var list = winreg_enum_path(reg, path); +function list_values(path) { + var list = winreg_enum_values(reg, path); var i; if (list == undefined) { return; } for (i=0;i<list.length;i++) { + printf("\ttype=%2d size=%4d '%s'\n", list[i].type, list[i].size, list[i].name); + } +} + +function list_path(path) { + var list = winreg_enum_path(reg, path); + var i; + list_values(path); + for (i=0;i<list.length;i++) { var npath; if (path) { npath = path + "\\" + list[i];