Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Wow, I wrote a simcall! 11 files to modify to do a simple get_size on a
[simgrid.git] / src / msg / msg_io.c
index 008c7bf..09188a3 100644 (file)
@@ -103,6 +103,18 @@ int MSG_file_unlink(msg_file_t fd)
   return res;
 }
 
+/** \ingroup msg_file_management
+ * \brief Return the size of a file
+ *
+ * \param fd is the file descriptor (#msg_file_t)
+ * \return the size of the file (as a size_t)
+ */
+
+size_t MSG_file_get_size(msg_file_t fd){
+  size_t size = simcall_file_get_size(fd->simdata->smx_file);
+  return size;
+}
+
 /** \ingroup msg_file_management
  * \brief Search for file
  *