Author Topic: Some fs-registry related issues  (Read 14936 times)

Jungle

  • Contributor
  • VIP Member
  • *****
  • Posts: 556
  • Old Skull
    • View Profile
Some fs-registry related issues
« on: October 08, 2011, 18:13:05 »
1. How can i edit registry param? I can create but have no idea how to edit.

2. Enter some registry path with existing parameters (i've created test path and params for experiments). Now open Windows registry editor and enter the same path. Now edit some parameters ans return to MC. Exit the path and enter it again - all values remains unchanged until you manually refresh the panel view.

3. I think some actions should be disabled for fs-registry (and other specific plugins). E.g. it is impossible to change file attributes or pack registry parameters

Moreover, they may have unpredictable results. Example.
a) Open Windows registry editor, create some test folder.
b) Create two different keys with the same data. E.g "Param1" with type REG_SZ and value "test", and "Param2" with type REG_BINARY and value "74 00 65 00 73 00 74 00 00 00" (all without quotes).
c) In MC pack this folder to some disk path, then delete this folder in registry and unpack from archive
Result: there are 2 these parameters in the folder but both have type REG_SZ

I haven't explored much but i suppose that such 'unusual' actions may even sometimes be dangerous.

Mathias (Author)

  • Administrator
  • VIP Member
  • *****
  • Posts: 4492
    • View Profile
    • Multi Commander
Re: Some fs-registry related issues
« Reply #1 on: October 08, 2011, 18:27:08 »
1. ?? You edit registry values by double clicking and pressing return on a registry value

2. Yes. for new you must manually refresh registry path to see latest values. It does not recognize if something has change outside of MC.. (yet.)

3. Yes you are right.

Packing registry path hmm Do not do that :).. maybe need to but in some more locks on what can be done.

Registry values are handled as files. And when copying them out from the registry to disk they becomes files, and when copying them back into the registry it does not know what kind of datatype the registry value are. It tries to guess it, but sometimes it guess wrong. (Specially with binary data, that looks like string data)

I do not want to disable the copy registry value to file. As I find it very useful myself. But maybe a warning is needed first the you do it or something..

Recommended is to use "Export to reg file" from the context menu.

Jungle

  • Contributor
  • VIP Member
  • *****
  • Posts: 556
  • Old Skull
    • View Profile
Re: Some fs-registry related issues
« Reply #2 on: October 08, 2011, 19:13:03 »
1. Shame on me, i haven't tried this :)
3. Maybe MC should not guess the type when copying files to registry, but should istead ask for a type with a possibility to apply the choice to all files?

P.S. This is just a particular case and warning may be enough. But in general there could be different ways of using the same operations on different types of plugins (or even between them) and not always you can predict what a user can do. So maybe a check should be done to block 100% 'incompatible' actions like change filetime for registry params. IMHO such approach has at least 2 'pros':
1. You protect a user from potentially bad things
2. You protect yourself from possible wasting time on debugging/remaking and reading angry comments :)